没有参数的窗口

时间:2012-03-21 09:14:48

标签: asp.net silverlight url parameters

如何将参数从silverlight(xaml页面)传递到aspx页面而不在url链接上显示?

如果我这样做:

HtmlWindow hw = System.Windows.Browser.HtmlPage.PopupWindow(new Uri(path), "rptapp", options);

它会传递我的参数,但它们会显示在网址中。

我不想加密它们......我只是不要出现在那里

1 个答案:

答案 0 :(得分:1)

在您的页面中创建一个表单,您可以在其中托管Silverlight应用程序的XAP文件,并使用post方法将表单提交到新网址。

使用链接填充action属性并向其添加输入元素:

<form id="popupform" action="" method="post" target="_blank" style="visibility: collapse" enctype="multipart/form-data" />

在此处阅读更多内容:How to remove all children in HtmlElement with Silverlight/C#