AspdotnetCodes.com
Search
Articles
Books
Resources
Asp.Net News
Downloads
Free Tech Magazines
Asp.Net Web Hosting
Archives
Softwares
Newsletter
Suggest Us
Link to Us
Feeds Subscription
Articles
Questions & Answers
Tips & Tricks
 How To Pass Multiple QueryString or Parameter in Hyperlink NavigateUrl from GridView?
Posted by Moderator1 on  12/31/2009 4:27:06 AM 4357 Views
The information provided here will help you to frame more than one QueryString parameter in a HyperLink control placed inside GridView control and also shows you, how to pass multiple QueryString in the HyperLinkField of the GridView control.

1. Passing Multiple QueryStrings From HyperLink Inside GridView TemplateField Section

<asp:HyperLink ID="HyperLink1" runat="server" Text="View Data"
NavigateUrl='<%# String.Format("TestPage.aspx?param1={0}&param2={1}&param3={2}", Eval("Field1"), Eval("Field2"), Eval("Field2")) %>'></asp:HyperLink>


2. Passing Multiple QueryString From HyperLinkField of GridView Control

<asp:HyperLinkField DataNavigateUrlFields="Field1,Field2,Field3" DataNavigateUrlFormatString="TestPage.aspx?param1={0}&param2={1}&param3={2}" Text="View Data" />

Post New Tips/Tricks View all Tips/Tricks

Featured Resources:
Simply SQL - Free 111 Page Preview!
Simply SQL is a practical step-by-step guide to writing SQL.
Oracle Magazine
Contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more.
100% Free Subscription until Stock lost.View complete list.
Sponsored by