Stop processing of ASP-script 
Author Message
 Stop processing of ASP-script

I have a loooong ASP-script in an ASP-page, that amongst other things
validate input from a FORM. I would like to be able to "raise a flag" when
certain things occur - and then stop the execution of the ASP-script.

I could do this by making the entire script into a function, but I would
preferebly avoid that. Is there any other way to do this ?

Thanks,

Jesper Stocholm

--
Why don't we go see a play tonight ?
    - Wife of Abraham Lincoln



Mon, 28 Jul 2003 18:33:27 GMT  
 Stop processing of ASP-script

Quote:

> I have a loooong ASP-script in an ASP-page, that amongst other things
> validate input from a FORM. I would like to be able to "raise a flag" when
> certain things occur - and then stop the execution of the ASP-script.

> I could do this by making the entire script into a function, but I would
> preferebly avoid that. Is there any other way to do this ?

> Thanks,

> Jesper Stocholm

> --
> Why don't we go see a play tonight ?
>     - Wife of Abraham Lincoln

Do you want the whole script to be abandoned?
If so, wrapping the whole thing in a transaction will allow you to abort it at
any given point.

Nick.



Tue, 29 Jul 2003 01:24:11 GMT  
 Stop processing of ASP-script

Quote:

> I have a loooong ASP-script in an ASP-page, that amongst other things
> validate input from a FORM. I would like to be able to "raise a flag"
> when
> certain things occur - and then stop the execution of the ASP-script.

> I could do this by making the entire script into a function, but I
> would
> preferebly avoid that. Is there any other way to do this ?

> Thanks,

> Jesper Stocholm

> --
> Why don't we go see a play tonight ?
>     - Wife of Abraham Lincoln

if you want to break out of the script, chuck this sub in, and call
that.

sub KillTheScript
        response.end
end sub

Keif Gwinn



Tue, 29 Jul 2003 02:51:00 GMT  
 Stop processing of ASP-script

Quote:
> if you want to break out of the script, chuck this sub in, and call
> that.
> sub KillTheScript
> response.end
> end sub

Or simply just use the Response.End in the script , Response.end imediately
stops all script execution. And if page buffering is turned on for the page
the buffer is flushed before ending execution.

--
Jakob Andersen
Denmark



Wed, 30 Jul 2003 19:27:43 GMT  
 Stop processing of ASP-script

Quote:


> > if you want to break out of the script, chuck this sub in, and call
> > that.
> > sub KillTheScript
> > response.end
> > end sub

> Or simply just use the Response.End in the script , Response.end
> imediately
> stops all script execution. And if page buffering is turned on for
> the page
> the buffer is flushed before ending execution.

> --
> Jakob Andersen
> Denmark

Yup. I was having a weird day... I don't know why I said put it in a
sub :)

Keif Gwinn



Sat, 02 Aug 2003 22:06:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Help with selected fields, Please

2. BDE, InterBaseLocal, ODBC install blues

3. Browser Stop Button: when does ASP script stop?

4. Stopping a Service or Killing a Process with VBScript and WMI in ASP

5. stopping users from stopping background process

6. Weirdness with debugging - STOP not stopping script

7. Create a new Process thread in ASP using vb script

8. Choosing a scripting language to use (Re: Client-side processing in asp.net)

9. I/O in turbo pascal 7.0

10. Turbo Pascal Programs, for Windows 3.x

11. D4: CreateTable problem

12. Delphi: Printing to serial printers connected to RS232?

 

 
Powered by phpBB® Forum Software