question on refresh

  • Thread starter Thread starter Mark
  • Start date Start date
M

Mark

Hi,

I don't know if I'm just missing something obvious, but when running my app,
not matter what page I'm on, when I hit 'refresh' on my browser, it takes me
back to my homepage.


I'm using global.asax and webconfig to fire some session onstart events and
to set a few variables (connstring and such) and also for forms
authentication.

I don't think I modified anything to cause this.. I didn't notice the
problem till now, as I finally have enough of it completed that I can view
other pages (lol).

Any idea on what is causing this problem?
 
My first guess would be that you're using Server.Transfer to send the user
between pages. This causes the original URL to remain in the browsers
address bar. Therefore when you tell the browser to refresh, that's the
address it refreshes.

My second guess would be that you're using frames, and the browser simply
refreshes the top frameset.
 
I should have stated, I am using frames--a header frame and a content frame
(titled 'main'). Is there any way around the refresh problem in this
situation? I only want to refresh the 'main' frame.
 
That is a difficult problem to solve.
This is one of the (many) reasons that frames should be avoided.
Usually you can partition logical sections of your page into web controls
instead of using frames. It's normally a better and more object oriented
aproach
Here's more info:
http://msdn.microsoft.com/library/d...n/html/vbconintroductiontowebusercontrols.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon/html/vboriwebusercontrols.asp
http://msdn.microsoft.com/library/d...l/vbconWebUserControlsVsCustomWebControls.asp

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://Steve.Orr.net
Hire top-notch developers at http://www.able-consulting.com
 
Back
Top