Redirecting

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Vajrala Narendra
    New Member
    • Jun 2007
    • 73

    Redirecting

    Hi, Please help me

    the situation is

    in my asp.net application i have few folders and forms, in few folders again i have forms,the folders and application have their individual main pages, here the problem am getting is while running my application from folder form to mainpage is not redirecting.

    please pass solution.

    ex:

    my application contain

    form1.aspx, form2.aspx, mainpage.aspx,f older1,folder2
    and in folder1 form3.aspx,main page1.aspx,
    in folder2 form4.aspx, mainpage2.aspx. ......like this forms are there
    while running
    i have redirect from folder1--> form3.aspx to mainpage.aspx

    i used response.redire ct techniques but not working.
  • Spippo
    New Member
    • Nov 2007
    • 15

    #2
    You can always go up to the parent directory like this:

    ../mainform.aspx

    Comment

    • Ramchandar
      New Member
      • Dec 2007
      • 11

      #3
      Originally posted by Vajrala Narendra
      Hi, Please help me

      the situation is

      in my asp.net application i have few folders and forms, in few folders again i have forms,the folders and application have their individual main pages, here the problem am getting is while running my application from folder form to mainpage is not redirecting.

      please pass solution.

      ex:

      my application contain

      form1.aspx, form2.aspx, mainpage.aspx,f older1,folder2
      and in folder1 form3.aspx,main page1.aspx,
      in folder2 form4.aspx, mainpage2.aspx. ......like this forms are there
      while running
      i have redirect from folder1--> form3.aspx to mainpage.aspx

      i used response.redire ct techniques but not working.
      Hi,
      May be u can try getting the application vitual path.
      Response.Redire ct(Request.Appl icationPath + "/main.aspx");

      This Request.Applica tionPath will get you the virtual path of ur application.

      Hope this was usefull..

      With regards,
      ram

      Comment

      • Frinavale
        Recognized Expert Expert
        • Oct 2006
        • 9749

        #4
        Originally posted by Spippo
        You can always go up to the parent directory like this:

        ../mainform.aspx
        I blieve you can also use a relative path:

        ~/mainform.aspx

        The "~/" refers to your application's root directory.

        Comment

        Working...