The Media Center Sandbox

Resources and discussion for developing experiences in the Windows Media Center platform.
Welcome to The Media Center Sandbox Sign in | Join | Help
in Search

AddInHost.MediaCenterEnvironment.NavigateToPage - Problem when using "&" character

Last post 08-24-2010, 4:43 AM by thus. 1 replies.
Sort Posts: Previous Next
  •  08-24-2010, 2:28 AM 9841

    AddInHost.MediaCenterEnvironment.NavigateToPage - Problem when using "&" character

    I am trying to navigate my MCML page to an another website by the following code:

    -Changed Source="[CMD_MyCommand.Invoked]"-
    -Actions-
    -Invoke Target="[AddInHost.MediaCenterEnvironment.NavigateToPage]"
    pageId="ExtensibilityURL"
    pageParameters="[sLink]"-
    -/Invoke-
    -/Actions-
    -/Changed-

    This MCML code is working but the compiler doesn't accept the "&" character and gives error?

    My link is like: "http://www.domain.com?param1=test¶m2=test1¶m3=test3"

    I replaced "&" with "%26". This time I didn't receive an error but the link I have changed didn't open in Media Center. Then I checked the link with using "%26" in browser. The web site can not understand the paramaters.

    So, how can I use "&" characters in a link in MCML? Thank you..
  •  08-24-2010, 4:43 AM 9842 in reply to 9841

    Re: AddInHost.MediaCenterEnvironment.NavigateToPage - Problem when using "&" character

    The solution is quite easy. All you need to do is to replace & with &

    I forgot MCML files work as XML and include the HTML basics, sorry :)
View as RSS news feed in XML
Powered by Community Server, by Telligent Systems