Here is the corrected version,
<asp:datagrid id="Datagrid1"
runat="server" AutoGenerateColumns="False" BorderColor="black"
HeaderStyle-CssClass="tableHeader"
ItemStyle-CssClass="tableItem">
<Columns>
<asp:TemplateColumn HeaderText="Order">
<ItemTemplate>
<asp:Hyperlink runat="server" Text= '<%#
DataBinder.Eval(Container.DataItem,"ProductName"). tostring %>'
NavigateUrl='<%# "page.aspx?Name=" & DataBinder.Eval
(Container.DataItem,"ProductName").tostring & _
"&ProductID=" &
DataBinder.Eval(Container.DataItem,"ProductID").to string %>'
ID="ProductName"/>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
Check out now, if you still face problem. Let me know about it.
--
-Saravana
http://dotnetjunkies.com/WebLog/saravana/ www.ExtremeExperts.com
"Chris" <Ch***@discussions.microsoft.com> wrote in message
news:83**********************************@microsof t.com...
I tried this and as I thought, it doesn't appear to allow <% %>.
So when you look at the link it lists the text:
<%Request.Params("tab")%>&id=<%#DataBinder.Eval(Co ntainer.DataItem,"SurveyRe
sponseheaderid")%>'
"Gopal (FMS, Inc.)" wrote:
How about this? Does this work for you?
<asp:datagrid id="Datagrid1" runat="server" AutoGenerateColumns="False"
BorderColor="black"
HeaderStyle-CssClass="tableHeader" ItemStyle-CssClass=
"tableItem"> <Columns>
<asp:TemplateColumn HeaderText="MyCol">
<ItemTemplate>
<asp:Hyperlink runat="server"
Text='<%#DataBinder.Eval(Container.DataItem,"Name" )%>'
NavigateUrl='pagename?tab=<%Request.QueryString("t abname")%>&id=<%#DataBinde r.Eval(Container.DataItem,"SurveyResponseheaderid" )%>' ID="Hyperlink1"/>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
--
Gopal Rangaswamy
Microsoft Certified Solutions Developer
FMS, Inc.
<http://www.fmsinc.com/consulting>
<http://www.fmsinc.com/dotnet/SourceBook/>
"Chris" <Ch***@discussions.microsoft.com> wrote in message
news:8E**********************************@microsof t.com... I've tried several posting examples to no avail.
I'm trying to pass two parameters to the hyperlink inside of the grid.
I've gone to this link that was posted, and besides the typo (missing '>')
I can't get it to work.
http://www.extremeexperts.com/Net/fa...inURLLink.aspx
Does anyone have a working example?
need: pagename?tab=(tabname)&id={0}
first is a request.param value (tabname)
second is a container field (SurveyResponseheaderid)
Help......Thanx.