Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / February 2008

Tip: Looking for answers? Try searching our database.

sending two parameters over to another page

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
JJ297 - 06 Feb 2008 19:06 GMT
I want to send Titleid and [descriptions] over to the other page how
do I do this?  I know how to send one how do I add another?

Response.Redirect("checkoutItem.aspx?TitleID=" &
GridView1.SelectedValue)

Thanks!
Andrew - 06 Feb 2008 20:10 GMT
Response.Redirect(string.format("checkoutItem.aspx?TitleID={0}&Description={1}", GridView1.SelectedValue, DescriptionVar);
siccolo - 06 Feb 2008 21:08 GMT
> I want to send Titleid and [descriptions] over to the other page how
> do I do this?  I know how to send one how do I add another?
[quoted text clipped - 3 lines]
>
> Thanks!

aaa....use "&" delimeter?
Response.Redirect ("kuku.aspx?TitleID=999&SecondValue=666")
JJ297 - 06 Feb 2008 21:14 GMT
> > I want to send Titleid and [descriptions] over to the other page how
> > do I do this?  I know how to send one how do I add another?
[quoted text clipped - 6 lines]
> aaa....use "&" delimeter?
> Response.Redirect ("kuku.aspx?TitleID=999&SecondValue=666")

Tried this but it's still not working.

Response.Redirect("checkoutitem.aspx?Titleid= " & "classificationid= "
& GridView1.SelectedValue)
sloan - 06 Feb 2008 21:39 GMT
You should UrlEncode and UrlDecode the values as well.

http://msdn2.microsoft.com/en-us/library/system.web.httputility.urlencode.aspx

On Feb 6, 4:08 pm, siccolo <aleks...@hotmail.com> wrote:
> On Feb 6, 2:06 pm, JJ297 <nc...@yahoo.com> wrote:
>
[quoted text clipped - 8 lines]
> aaa....use "&" delimeter?
> Response.Redirect ("kuku.aspx?TitleID=999&SecondValue=666")

Tried this but it's still not working.

Response.Redirect("checkoutitem.aspx?Titleid= " & "classificationid= "
& GridView1.SelectedValue)
siccolo - 06 Feb 2008 22:31 GMT
> You should UrlEncode and UrlDecode the values as well.
>
[quoted text clipped - 19 lines]
> Response.Redirect("checkoutitem.aspx?Titleid= " & "classificationid= "
> & GridView1.SelectedValue)

there's extra "&" needed:

Response.Redirect("checkoutitem.aspx?Titleid= " & "&classificationid=
"
& GridView1.SelectedValue)
Mr. R - 07 Feb 2008 00:53 GMT
HI

Don't know if this make sence or not but I think the error might be because
you add SPACES between the double quat " and the &. You also us one " and
then the & you need two "" to send an empty string or maybe =& without any "
to send an empty string. Also to add " to a string you probably need to do
some thing like \". I'm new to C# but that's how you do it in C/C++.

The following line looks like VB code
Response.Redirect("checkoutitem.aspx?Titleid= " & "classificationid= " &
GridView1.SelectedValue)

I "think" the right C# code would be
Response.Redirect("checkoutitem.aspx?Titleid=" + "&classificationid=&" +
GridView1.SelectedValue );

Or is this VB Code? Then try skip the spaces only. Note that the & are
within the quated strings. How does C#ASP act on null parameters. Does ASP
act the same way as PHP?

Try This
Response.Redirect("checkoutitem.aspx?Titleid=999&classificationid=" +
GridView1.SelectedValue);

Don't forget the ";" at the end of the line. If you do it will give you a
compiler error (I guess)

Lars

On Feb 6, 4:08 pm, siccolo <aleks...@hotmail.com> wrote:
> On Feb 6, 2:06 pm, JJ297 <nc...@yahoo.com> wrote:
>
[quoted text clipped - 8 lines]
> aaa....use "&" delimeter?
> Response.Redirect ("kuku.aspx?TitleID=999&SecondValue=666")

Tried this but it's still not working.

Response.Redirect("checkoutitem.aspx?Titleid= " & "classificationid= "
& GridView1.SelectedValue)

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.