473,398 Members | 2,404 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

datagrid passing parameters problem

I have a datagrid with a hyperlink field. It passes a parameter but I need
it to pass three. I need two of the parameters to be querystrings that have
already been passed to the page but I have no idea how to add them the the
hyperlink column.

Here is the code to the hyperlink column

<asp:HyperLinkColumn
HeaderText="strProductName"
Visible="True"
DataTextField="strProductName"
DataNavigateUrlField="intProductID"
DataNavigateUrlFormatString="details.aspx?ProductI D={0}"/>
<asp:BoundColumn DataField="curPrice"
HeaderText="curPrice"
ReadOnly="true"
Visible="True"/>

Here is the code if it were to be outside the datagrid.

<a href="details.aspx?prodID=<%# dsSubCategory.FieldValue("intProductID",
Container) %>&strCssPath=<%= Request.QueryString("StrCSSPath")
%>&strSubCategory=<%=
server.UrlEncode(Request.QueryString("strSubCatego ry")) %>">

I have taken care of the details.aspx?#
dsSubCategory.FieldValue("intProductID", Container) %>

but I do not know how to pass the existing parameters

Any help appreciated.

Thanks
Laura K

Nov 19 '05 #1
1 1426
Check out this faq,
http://www.extremeexperts.com/Net/fa...inURLLink.aspx

--
Saravana
http://dotnetjunkies.com/WebLog/saravana/
www.ExtremeExperts.com
"Laura K" <kl*******@ATcharter.net> wrote in message
news:eJ**************@TK2MSFTNGP15.phx.gbl...
I have a datagrid with a hyperlink field. It passes a parameter but I need it to pass three. I need two of the parameters to be querystrings that have already been passed to the page but I have no idea how to add them the the
hyperlink column.

Here is the code to the hyperlink column

<asp:HyperLinkColumn
HeaderText="strProductName"
Visible="True"
DataTextField="strProductName"
DataNavigateUrlField="intProductID"
DataNavigateUrlFormatString="details.aspx?ProductI D={0}"/>
<asp:BoundColumn DataField="curPrice"
HeaderText="curPrice"
ReadOnly="true"
Visible="True"/>

Here is the code if it were to be outside the datagrid.

<a href="details.aspx?prodID=<%# dsSubCategory.FieldValue("intProductID",
Container) %>&strCssPath=<%= Request.QueryString("StrCSSPath")
%>&strSubCategory=<%=
server.UrlEncode(Request.QueryString("strSubCatego ry")) %>">

I have taken care of the details.aspx?#
dsSubCategory.FieldValue("intProductID", Container) %>

but I do not know how to pass the existing parameters

Any help appreciated.

Thanks
Laura K

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: bpschmid | last post by:
Ive got a datagrid with a hyperlink column. I want to click on that column and go to another page, but here's the kicker, I need and want to pass not one, but two different query string parameters...
0
by: lu | last post by:
I have a page with datagrid (for viewing, delete,edit,update) and text fields with button to add info to database. When user comes to page the datagrid selects info from database, binds in...
7
by: Harolds | last post by:
The code below worked in VS 2003 & dotnet framework 1.1 but now in VS 2005 the pmID is evaluated to "" instead of what the value is set to: .... xmlItems.Document = pmXML // Add the pmID...
5
by: Jeff | last post by:
IDE: VS 2003 :NET OS: XP Pro My app have a form with a tab-control on it. The tab-control have 2 tabpages. One of the tabpages displays a datagrid, and the other tabpage displays details (order...
2
by: ddaniel | last post by:
I have read many posts and seen many papers on the different techniques for sort and filtering datagrids. Many do re-queries against the dB ala Fritz Onion. I am trying to leverage the Dataview....
1
by: I am Sam | last post by:
I need to be able to delete a record/row from a database table. I am using a DataGrid which is not sending the row index key properly to the event in the codebehind. When I set a break point and...
3
by: thebison | last post by:
Hi all, I hope someone can help with this relatively simple problem. I am building a timesheet application using ASP.NET C# with Visual Studio 2003.As it is only a protoype application, my...
8
by: preeti13 | last post by:
I have a datagrid with a hyperlink field. It passes a parameter but I need it to pass two. I need two of the parameters to be querystrings but I have no idea how to add them the hyperlink column if...
1
by: Amit | last post by:
Hello , Is there any way i can import data from datagrid to sqlserver. please advise . thanks & Regards
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.