Retreive将变量从Windows传递到Web应用程序

Retreive将变量从Windows传递到Web应用程序

问题描述:





我们在ASP.NET窗口中有一个应用程序,我们将按钮点击的用户凭据传递给Web应用程序页面。我们需要检索在网页的页面加载中传递了varaiables。



我们通过windows应用程序以下面提到的格式传递了varaiables。

string strUrl =http:// localhost:50541 / ZenjICTCTransaction / Login.aspx?UserID =+ tbUserID.Text +& Password =+ tbPassword.Text +;

Process.Start( iexplore,strUrl);





在登录页面中我们需要获得varaibale值。我们尝试使用


Hi,

We have an application in ASP.NET windows,where we pass user credentials on button click to a web application page.We need to retreive the passed varaiables in the page load of the web page.

We passed the varaiables in the below mentioned format through windows application.
string strUrl = "http://localhost:50541/ZenjICTCTransaction/Login.aspx?UserID=" + tbUserID.Text + "&Password=" + tbPassword.Text + "";
Process.Start("iexplore", strUrl);


In the login page we need to get the varaibale values.We tried to retreive using

Dim UserID As String = Request.Form("UserID")
        Dim UserPass As String = Request.Form("Pasword")







但是价值没有得到。



请帮助



问候

Sreejith




But the value is not getting.

Please help

Regards
Sreejith

您好,



如果您通过将数据附加到网址传递数据,则可以使用请求对象查询字符串 [ ^ ]检索值的方法。



看看这篇文章的一些内容更多示例传递使用QueryString的页面之间的变量 [ ^ ]



使用 Request.Form Collection [ ^ ]您发布的示例,需要您将值添加到表单集合中,然后发布表单。



..希望它有所帮助。
Hi,

If your passing data by appending it to the url, you would use the Request objects QueryString[^] method to retrieve the values.

Have look at this article for some more examples Passing variables between pages using QueryString[^]

To use the Request.Form Collection[^] example you posted, would require you to add the values to the form collection, and then post the form.

... hope it helps.