How to pass parameter to a Windows application Form the way it can be done in a web form
-
I'm using vb.net application form My form requests user to enter ID in text area to retreive some data for printing I want to know is it possible to pass this ID as a paramter when I call the web application form without requesting user to submit it I mean that I will send user link of the application form with the ID as a parameter just as we do in a web form.
-
I'm using vb.net application form My form requests user to enter ID in text area to retreive some data for printing I want to know is it possible to pass this ID as a paramter when I call the web application form without requesting user to submit it I mean that I will send user link of the application form with the ID as a parameter just as we do in a web form.
You could do this by appending it to the url. For example if you had two documents and depending on the value sent to your application it would print one of the two. So you could do something like the following http://www.yourwebsite.com?formId=1 In your application you would then parse the url to get that id. You could either do a hidden field or a label and use the following code C#: Request["formId"]; VB.net: Request("formId") so if you have your vb application you would want to do something like DIM strPrintId as String strPrintId = Request("formId") You would probably want to wrap that in a condition and have a default value. Hope this helps Matthew Vass QA Analyst mvass@hostmysite.com http://www.hostmysite.com?utm_source=bb[^]