473,748 Members | 2,294 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Stopping running code at a certain point

Hi,
I have a asp page which is pretty long. This consitst of various recordsets.
My intention is to stop execution of a code at a cetain point and test one
value prior to this point. Is there any way to do this? Thanks in advance.
Regards.
Jul 22 '05 #1
5 1402
"Jack" <Ja**@discussio ns.microsoft.co m> wrote in message
news:3F******** *************** ***********@mic rosoft.com...
Hi,
I have a asp page which is pretty long. This consitst of various recordsets. My intention is to stop execution of a code at a cetain point and test one
value prior to this point. Is there any way to do this? Thanks in advance.
Regards.


An "If" statement comes to mind as in:

If item = value Then
' do something
End If

Perhaps a more detailed description of the issue would suggest a different
answer.

What do you mean by "stop execution of the code"?

Will this require user interaction?
Jul 22 '05 #2

"Jack" <Ja**@discussio ns.microsoft.co m> wrote in message
news:3F******** *************** ***********@mic rosoft.com...
Hi,
I have a asp page which is pretty long. This consitst of various
recordsets.
My intention is to stop execution of a code at a cetain point and test one
value prior to this point. Is there any way to do this? Thanks in advance.
Regards.


Try:
Response.End();
after you've completed testing the value.
Jul 22 '05 #3
Thanks McKirahan for your answer. Actually, I need to log into the system.
That is the only user interaction. I would like to check couple of values of
variables which are in the middle of the code. Just after this, the code is
giving error. I was wondering if I could open the web page and the code would
run upto this point of extracting the values of couple of variables and not
execute any further which, at this point, if runs, will give me error in the
page. Hope I am clear.
I am going to test Vic's suggestion, to see if that works. Regards.

"McKirahan" wrote:
"Jack" <Ja**@discussio ns.microsoft.co m> wrote in message
news:3F******** *************** ***********@mic rosoft.com...
Hi,
I have a asp page which is pretty long. This consitst of various

recordsets.
My intention is to stop execution of a code at a cetain point and test one
value prior to this point. Is there any way to do this? Thanks in advance.
Regards.


An "If" statement comes to mind as in:

If item = value Then
' do something
End If

Perhaps a more detailed description of the issue would suggest a different
answer.

What do you mean by "stop execution of the code"?

Will this require user interaction?

Jul 22 '05 #4
"Jack" <Ja**@discussio ns.microsoft.co m> wrote in message
news:F2******** *************** ***********@mic rosoft.com...
Thanks McKirahan for your answer. Actually, I need to log into the system.
That is the only user interaction. I would like to check couple of values of variables which are in the middle of the code. Just after this, the code is giving error. I was wondering if I could open the web page and the code would run upto this point of extracting the values of couple of variables and not execute any further which, at this point, if runs, will give me error in the page. Hope I am clear.
I am going to test Vic's suggestion, to see if that works. Regards.


Use
Response.Write( variable_name)
before
Response.End
to view variable_name at the point of termination

If you use it multiple times. use:
Response.Write( "<br>variable_n ame = " & variable_name)
Jul 22 '05 #5
Thanks for your input McKirahan. Regards.

"McKirahan" wrote:
"Jack" <Ja**@discussio ns.microsoft.co m> wrote in message
news:F2******** *************** ***********@mic rosoft.com...
Thanks McKirahan for your answer. Actually, I need to log into the system.
That is the only user interaction. I would like to check couple of values

of
variables which are in the middle of the code. Just after this, the code

is
giving error. I was wondering if I could open the web page and the code

would
run upto this point of extracting the values of couple of variables and

not
execute any further which, at this point, if runs, will give me error in

the
page. Hope I am clear.
I am going to test Vic's suggestion, to see if that works. Regards.


Use
Response.Write( variable_name)
before
Response.End
to view variable_name at the point of termination

If you use it multiple times. use:
Response.Write( "<br>variable_n ame = " & variable_name)

Jul 22 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1437
by: UJ | last post by:
I've got a program that will do some updates to the system. During that time, if a certain program, called a.exe is running, I want to stop the program, do what I need to do and restart the program. How can I find out if a.exe is currently running and stop it? TIA - UJ.
16
2601
by: TB | last post by:
Hi all: If you think that the following comments are absolute amateurish, then please bear with me, or simply skip this thread. A couple of months back I made the decision to initiate a gradual upgrade of my web programming skills from Classic ASP / VBS to ASP.NET / VB.NET. While the study of the language differences and all the new features in .NET has so far not been a traumatic experience, I am a bit shell-schocked after
4
16401
by: MSDousti | last post by:
Hi I have written a VB .NET app, which uses several threads. I thought that when the user closes the main window (when MainForm.closed event occures, and I call application.exit) all running threads must abort, but to my great surprise, running threads do not stop when application.exit is called. So I (or the users) have to stop threads using Ctrl-Alt-Del. Is there a way to stop ALL threads with a single instruction, without having to...
5
17455
by: chris.hearson | last post by:
How do I programmatically prevent a service from stopping? I want to be able to keep my service running (started), under certain conditions, when a user tries to stop it. I have tried throwing an exception - from OnStop(): the SCM waits for a long time, reports that the service didn't respond in a timely fashion and then leaves the status as stopping. - from Dispose(): the SCM displays an error dialog with the exception details and...
11
2784
by: Nathan Sokalski | last post by:
I add several JavaScript events (onchange, onkeypress, etc.) to Controls using the Add method of the Attributes collection. However, if the JavaScript code contains certain characters, such as & or < or several others, it converts them to html, such as &amp; or &lt; which can sometimes cause my scripts not to work. How can I prevent ASP.NET from doing this? Thanks. -- Nathan Sokalski njsokalski@hotmail.com http://www.nathansokalski.com/
6
2665
by: Andrew Poulos | last post by:
I'm using Windows Media Audio, via a WAX file, and I have some custom controls to start and stop the audio. While it works in IE, FF gives an error. The HTML looks like this: <object id='obj' type='audio/x-ms-wax' style='position:absolute; left:0px; top:0px;' classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' codeBase='http://activex... blah width='100' height='100'> <param name='FileName' value='wma_sample.wax'>
4
1823
by: Bullitt | last post by:
Hey, I have a problem with a small program that I want to make. It's a script that keeps running by using a Do While loop. I want to stop the script when a certain key is pressed. But the problem is that the keypress sub isn't working because the other sub keeps running. Is there a way of doing this, or is there someone who knows how to replace the do while with the use of a timer or someting, so that I can make a pause between every run of...
7
1452
by: nelsonbrodyk | last post by:
Hey All, I am trying to make a textbox that will only allow alphanumeric values. I accomplished this by using the key pressed event, and validating the character against a regex and saying that the character is handled if the character does not match a regex. This works great, but it breaks in one case: Pasting into the text box. How can I accomplish my goal of stopping invalid pasting into the textbox as well? I have been trying to use the...
2
3365
by: Steve | last post by:
Hi All, I've been trying to come up with a good way to run a certain process at a timed interval (say every 5 mins) using the SLEEP command and a semaphore flag. The basic thread loop was always sitting in the sleep command and not able to be interrupted. When the time came to set the semaphore flag to false (stopping the thread), my program would have to wait up to the entire sleep time to break out of the loop. I have finally found...
0
9528
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9359
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9310
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8235
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6792
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4592
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3298
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2774
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2206
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.