How do you detect when a page has only been refreshed?

How do you detect when a page has only been refreshed?

am 04.02.2007 01:27:10 von JimO

I'm trying to write an ASP interface that mimiks a .Net datagrid control.
I'm having a problem when I'm in the middle of an Edit, Update, or a New
Record. If the user hits the wrong button, the program grabs the values in
the textboxes using the request.form() and then redisplays them in the
textboxes when the records table gets written back out to the page. This
works fine as long as the form is submitted. If it's just a page refresh
(F5), the program doesn't get the latest changes to the textboxes and
displays either a blank or whatever was in there the last time the form was
submitted. Anybody got any ideas?

Jim

Re: How do you detect when a page has only been refreshed?

am 05.02.2007 10:06:33 von Adrienne Boswell

Gazing into my crystal ball I observed "JimO"
writing in
news:yL9xh.20374$w91.13889@newsread1.news.pas.earthlink.net:

> I'm trying to write an ASP interface that mimiks a .Net datagrid
> control. I'm having a problem when I'm in the middle of an Edit,
> Update, or a New Record. If the user hits the wrong button, the
> program grabs the values in the textboxes using the request.form() and
> then redisplays them in the textboxes when the records table gets
> written back out to the page. This works fine as long as the form is
> submitted. If it's just a page refresh (F5), the program doesn't get
> the latest changes to the textboxes and displays either a blank or
> whatever was in there the last time the form was submitted. Anybody
> got any ideas?
>
> Jim
>
>
>

dim defaultvalues, defarr, iscompleted, required, name

defaultvalues = "Your name, your address, you@example.com"
defarr = split(defvaultvalues,", ")
if request.servervariables("request_method") = "POST" then
if request.form("name") = "Your name" then
required = "name"
end if
if required <> "" then
'do not complete processing
else
'complete processing
iscompleted = true
name = defarr(0)
end if
else
name = defarr(0)
end if

%>

">
name="name" id="name" value="<%=name%>" onfocus="if(this.value == '<%
=name%>') this.value = '';">

.....




--
Adrienne Boswell at Home
Arbpen Web Site Design Services
http://www.cavalcade-of-coding.info
Please respond to the group so others can share