Skip to content

Is it possible get something from previous page??

Joy

Asked Feb 5, 2007, 8:00 PM EST4 answers
Share
LinkedInX
 

I have a complex quesion about pass argument from page to another page

 

I've a webpage which is  forum's list

when I run it on IE . which address is display like ? ?http://localhost/news/news_c.aspx?cid=26&FK=1?

and now I have to write a page (use C#) for forum's content

I would like to catch "cid" from address of previous page

is it possible? if yes. how can I do it? can somebody give me a tip to start it? ( which class should I use? which namespace should I import?? )

thanks ...

 

( if I don't make my question clearly ... please let me know I will explain it.. many thanks)

4 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • 0
    Hi,

         If I am not wrong u r talking abt recieving querystring.....

    ...its very simple..write this line in the new page...e.i the page u r redirecting to....

            string var = Request.QueryString["CkID"];

    Regards
    0
  • 0
    Well I will give you a quick direction on this: Read about Server.Transfer or Diff between Server.Transfer and Response.Redirect. Thanks, Anup Daware
    0
  • 0
    thank you..

    sorry for the confusing

    I've not idea how to get parameter from URL

    example : /localhost/example.asp?parameter1

    How can i to get this parameter ?

    can you give me a example? ( using C#)


    thanks you all

    0
  • 0

    Hello,

    Resuest to page AddEditVehicle2.aspx:
    Response.Redirect ("AddEditVehicle2.aspx?mode="TEST"&mount=new");
     
    Use of mode on AddEditVehicle2.aspx:
    if (Request["mode"] == "TEST")

    Hope this helps you. Please let us know if this worked or if you have found some other approach.
    Thanks,
    Anup Daware


    0