Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Server.Transfer not loading template, Response.Redirect won't login

Status
Not open for further replies.

XgrinderX

Programmer
Mar 27, 2001
225
0
0
US
Is there a way to use Server.Transfer such that it will load template info? Right now I have an app that I did not right, I am maintaining, bug fixing, and adding features. One thing we added is templates - there are two templates. Depending on the URL, it loads one or the other. The logic for this is in global.asax.vb.

It appears that once we started doing this, all the Server.Transfer calls in the app would bring up pages without any style info loaded, as if the template is not being loaded at all. Is there a way to use Server.Transfer and have it load up the templates too?

Second to this - I know I can use Response.Redirect and it loads the templates just fine. However the strange part there is when we try to debug the app in on our PCs, the Response.Redirect from the login page doesn't seem to want to let us in the app. It ends up coming back to the login page as if we didn't get validated. It doesn't do this on our server environments, just when we debug it on our PCs. I don't understand why.

Any help is appreciated.

-Greg
 
Is there a way to use Server.Transfer and have it load up the templates too?

Server.Transfer switches processing from script a to script b, if your includes do not appear before the server.transfer is called. they are not going to be there.

Server.Execute(document) is probably what you should be using.

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Any ideas why Response.Redirect throws an exception when debugging from the IDE but works fine when running on the server?
 
Do we get a clue as to what the IDE is?

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Sorry - Visual Studio 2010

Nuff' said methinks [mad]


Some things only work correctly when running on a real http server.

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top