Solved

ASP.NET NavigateURL using Eval for multiple parameters

Posted on 2011-03-08
4
1,922 Views
Last Modified: 2012-05-11
I need to somehow get the VersionID into the NavigateURL URL string ("V_ID"), but I have no idea how to put more than one ID into the Eval statement and then add it to the URL.   Can someone help?

<asp:HyperLink ID="lnkProductName" runat="server" NavigateUrl='<%# Eval("P_ID", "~/Loan.aspx?ProductID={0}") %>'
0
Comment
Question by:saturation
  • 2
4 Comments
 
LVL 13

Expert Comment

by:agarwalrahul
Comment Utility
Use this code:

NavigateUrl='<%# string.format("page.aspx?val={0}", Eval("val")) %>'
0
 
LVL 12

Expert Comment

by:Kaushal Arora
Comment Utility
You can also use this:

NavigateUrl = '<%# "Loan.aspx?ProductID=" + Eval("P_ID").ToString() %>'
0
 
LVL 9

Accepted Solution

by:
gery128 earned 500 total points
Comment Utility
so you are trying to pass more than one parameters in query string:

Did you try this:
NavigateUrl='<%#"Loan.aspx?ProductId=" + EVAL("P_ID") + "&VersionId= + EVAL("V_ID")%>'
0
 
LVL 9

Expert Comment

by:gery128
Comment Utility
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now