Hi Ken,
When a user clicks a link from one page to the next, the HTTP_REFERER header
gets the URL of the referring page. The original poster can easily use that
value to reference where to go back to.
-- Nick
"Ken Dopierala Jr." <kdopierala2@wi.rr.com> wrote in message
news:%23HzT7KDqEHA.324@TK2MSFTNGP11.phx.gbl...[color=blue]
> Hi,
>
> This could be either easy or tough depending on how users are getting to
> your login page. Are they clicking a button or clicking a link? If they
> are clicking a button that causes a postback and then you redirect this[/color]
will[color=blue]
> be easy. Just create a quick session variable and put in the page that
> performed the redirect before you redirect. Then from your login just
> assign that Session variable to a string, set that Session variable to
> Nothing, and redirect them back. If you are using a hyperlink then I'm[/color]
not[color=blue]
> sure how you would do it. Maybe do a search on Environment variables that
> IIS holds, maybe one of those holds the page they came from. Other than
> that you'd have to hand code it. Or create a class that inherits
> System.Web.UI.Page, add code to the Page_Load of that base class to store
> the current page in the session, and then inherit that page whereever you
> have a link to the login page. Don't inherit the login page from this.
> Good luck! Ken.
>
> --
> Ken Dopierala Jr.
> For great ASP.Net web hosting try:
>
http://www.webhost4life.com/default.asp?refid=Spinlight
> If you sign up under me and need help, email me.
>
> "Terry Graham" <tjgraham4@hotmail.com> wrote in message
> news:uc6ya39pEHA.2764@TK2MSFTNGP11.phx.gbl...[color=green]
> > Actually I cannot use Forms Authentication at this point in the site so
> > I just need a simple way to redirect the user back to their last page
> > after they have filled out the login information. Can this be done?
> >
> > Thanks
> >
> >
> >
> > *** Sent via Developersdex
http://www.developersdex.com ***
> > Don't just participate in USENET...get rewarded for it![/color]
>
>[/color]