A
Arch Stanton
I have some data returned via a SQL statement (from MS Access) to a
datagrid on an ASPX page. One of my datagrid columns is a hyperlink
column. Everything works fine, but I need to pass the variable my user
clicks to another page.
Here's the code for my hyperlink column:
<asp:hyperlinkcolumn
datatextfield="SiteID"
headertext="Site ID"
datanavigateurlfield="SiteID"
datanavigateurlformatstring="CTSingleSite.aspx?SiteID=12-236" />
This code passes the string "12-236" to the receiving page just great,
but I need to replace that string with the string variable "SiteID" used
in this tag. I tried this:
datanavigateurlformatstring= _
"CTSingleSite.aspx?SiteID= '" & SiteID & "'"
But this causes an error. How can I pass the actual variable value, not
a hard-coded value?
Thanks much for any help.
datagrid on an ASPX page. One of my datagrid columns is a hyperlink
column. Everything works fine, but I need to pass the variable my user
clicks to another page.
Here's the code for my hyperlink column:
<asp:hyperlinkcolumn
datatextfield="SiteID"
headertext="Site ID"
datanavigateurlfield="SiteID"
datanavigateurlformatstring="CTSingleSite.aspx?SiteID=12-236" />
This code passes the string "12-236" to the receiving page just great,
but I need to replace that string with the string variable "SiteID" used
in this tag. I tried this:
datanavigateurlformatstring= _
"CTSingleSite.aspx?SiteID= '" & SiteID & "'"
But this causes an error. How can I pass the actual variable value, not
a hard-coded value?
Thanks much for any help.