Challenge: To read query string parameter in form init() method
Solution: URLUtility class is used to extract the query string parameters. To explain this, I have created a simple form designed to extract query string in the init method and display in a text control.
- A display menu item is attached with the form “Form1”
- A string control is attached and the “AutoDeclaration” property is set to “Yes”. Assign custom pattern to the form.
- Below code in the form init() method retrieves the query string information and set to the string control.
- Execute the menu-item linked with the Form and attach the following line in the url link
&queryParm=Hello,world
- The query string value is displayed in the text control.