473,388 Members | 1,220 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Running Batch Files using ASP .NET

Hi all,

I want to create an app that runs a batch file which inturn runs
applications.

question:
if I start the batch file from app1, how can app1 know that the batch file
ran successfully and there was no errors.. (is there a return type)
we run a lot of sql jobs using batch files, so we want to create a user
interface to run batch files

Please advice,
Stephen
Dec 21 '05 #1
2 1634
Stephen,

To start a batch you need to use System.Diagnostics.Process class. It has a
special property ExitCode for communicating return value.

Eliyahu

"Stephen" <st********@hotmail.com> wrote in message
news:es*****************@TK2MSFTNGP10.phx.gbl...
Hi all,

I want to create an app that runs a batch file which inturn runs
applications.

question:
if I start the batch file from app1, how can app1 know that the batch file
ran successfully and there was no errors.. (is there a return type)
we run a lot of sql jobs using batch files, so we want to create a user
interface to run batch files

Please advice,
Stephen

Dec 22 '05 #2
Thanks Eliyahu,
did use the process class... will check the exitcode method.
stephen

"Eliyahu Goldin" <re*************@monarchmed.com> wrote in message
news:Ou**************@tk2msftngp13.phx.gbl...
Stephen,

To start a batch you need to use System.Diagnostics.Process class. It has a special property ExitCode for communicating return value.

Eliyahu

"Stephen" <st********@hotmail.com> wrote in message
news:es*****************@TK2MSFTNGP10.phx.gbl...
Hi all,

I want to create an app that runs a batch file which inturn runs
applications.

question:
if I start the batch file from app1, how can app1 know that the batch file ran successfully and there was no errors.. (is there a return type)
we run a lot of sql jobs using batch files, so we want to create a user
interface to run batch files

Please advice,
Stephen


Dec 22 '05 #3

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

Similar topics

0
by: SkySea | last post by:
Hi! Any help on this would be appreciated... In an HTML document that lists instructions on installing some software, there's a point where a DOS batch file needs to be run in order to copy...
9
by: Doug at SAU | last post by:
I need to run a batch file on a remote machine from an ASP page. I dummied up a test ASP page as follows: <% Set WshShell = Server.CreateObject("Wscript.Shell") wshshell.run...
29
by: pb648174 | last post by:
I have a very long transaction that runs on the same database that other users need to use for existing data. I don't care if they see data from the transaction before it is done and am only using...
13
by: MLH | last post by:
I have a batch file named GetConf.bat. It contains a line like this: ipconfig /all >c:\MyAppDir\IPdata.txt I believe I could run the line with something like ShellWait by Terry Kreft. Any...
4
by: Shiraz | last post by:
Hi I'm using Visual Studio Installer to make my installer, and have not as yet figured out a straightforward way to use it to set environmental variables. Amongst the various things I tried, I'm...
1
by: Aaron West | last post by:
Try this script to see what queries are taking over a second. To get some real output, you need a long-running query. Here's one (estimated to take over an hour): PRINT GETDATE() select...
6
by: Mat N | last post by:
Hello access friends, (Originally posted on access.formsprogramming which I think was the wrong place) I'm precalculating a bunch of data for my clients as per a profile I have for each of...
0
by: sunrt | last post by:
We have an As400 system that has program which executes batch files which resides on the SQL server 7.0 computer . Those batch files run SQL server jobs using isql. The whole idea about this is...
3
by: John | last post by:
Hi. I have a number of batch jobs that are ran nightly on our Windows 2000 based Oracle 8.1.7 (soon to be 9i) server. I have these designed just right, so the Windows Scheduled Tasks runs them...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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...
0
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...

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.