Re: Scheduling the running of a batch file
From: David H. Lipman (DLipman~nospam~_at_Verizon.Net)
Date: 02/08/05
- Next message: J. K. Smith: "Re: Things that DON'T fix lost Search Files/Folders capability..."
- Previous message: Dave Patrick: "Re: disable8dot3 on or off??"
- In reply to: John Steen: "Re: Scheduling the running of a batch file"
- Next in thread: John Steen: "Re: Scheduling the running of a batch file"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 8 Feb 2005 12:58:50 -0500
If it is a batch file, try calling the batch file this way...
%comspec% /c <path>\MyBatchFile.BAT
-- Dave "John Steen" <moderndads(nospam)@hotmail.com> wrote in message news:AE15C9E9-0180-4DD8-A95F-759C35B94E40@microsoft.com... | I did as you suggested, Dave, but no go. The application still won't run. | Thanks for your help, though. | | John | | "David H. Lipman" wrote: | | > Study the concept of Redirection of Input and Output. | > | > In a command prompt, it I type; echo Dave | > | > The word Dave is shown on the screen | > | > it I type; echo Dave >c:\myfile | > | > The file "c:\myfile" would be created with the word Dave. | > | > it I type; echo Dave >>c:\myfile | > | > The file "c:\myfile" would be appended with the word Dave. | > | > Those are samples of Redirection of Output. | > | > If you have a program that requires the response "Y" five time, you can create a file such | > as"c:\myfile" with the following contents | > | > c:\myfile | > ----------- | > y | > y | > y | > y | > y | > | > | > | > I can then call my application (FOO.EXE) such that it uses the information in C:\MYFILE with | > the command... | > | > foo <c:\myfile | > | > Now FOO.EXE will obtain its responses from c:\myfile | > | > Of course, FOO.EXE has to be written to use Redirection of Input and Output. Most are, but | > not all. | > | > -- | > Dave | > | > | > | > | > "John Steen" <moderndads(nospam)@hotmail.com> wrote in message | > news:C204EF54-0D59-403E-B1A3-570006E6EA28@microsoft.com... | > | I checked, and the task runs under the administrar user, so rights aren't an | > | issue. | > | | > | How do I redirect input from an answers file? | > | | > | Thanks, | > | John | > | | > | "David H. Lipman" wrote: | > | | > | > You have to apply a user and password with sufficient rights to the job for the job to | > | > execute. If the application requires input redirect its input from an answer file. | > | > | > | > -- | > | > Dave | > | > | > | > | > | > | > | > | > | > "John Steen" <moderndads(nospam)@hotmail.com> wrote in message | > | > news:75CA9230-36A5-4C40-B613-E6905DE296FB@microsoft.com... | > | > | Setup: | > | > | | > | > | - Windows 2000 Server | > | > | - MS SQL2000 | > | > | | > | > | I have a VB6 application that modifies a SQL database that, when launched, | > | > | prompts the user to enter one of three parameters and press OK: | > | > | | > | > | X (cancels the application) | > | > | | > | > | ALL (modifies all records in the DB that have a null value in a particular | > | > | column, changing the null value in that column to a non-null value) | > | > | | > | > | <Registrant ID> (runs the application against the records with the above | > | > | parameters, but only for one particular registrant) | > | > | | > | > | The application runs fine when it's launched manually. I specify the ALL | > | > | option, click OK and it's done. It also runs fine when a batch file | > | > | containing the application name and option (application.exe ALL) is launched | > | > | from a command prompt. But when I create a scheduled task calling the batch | > | > | file at a particular time, the application fails to run at all. | > | > | | > | > | There is no indication of an error in Scheduled Tasks or Event Viewer, and | > | > | the status in Scheduled Tasks shows successful. But the records in the DB | > | > | are not modified, and the result window that appears when the application is | > | > | finished does not appear. | > | > | | > | > | Any idea why this is happening? I have other batch files that run fine as | > | > | scheduled tasks. Is there something about VB applications that prevent them | > | > | from running this way? | > | > | | > | > | Thanks! | > | > | | > | > | John Steen | > | > | | > | > | > | > | > | > | > | > | >
- Next message: J. K. Smith: "Re: Things that DON'T fix lost Search Files/Folders capability..."
- Previous message: Dave Patrick: "Re: disable8dot3 on or off??"
- In reply to: John Steen: "Re: Scheduling the running of a batch file"
- Next in thread: John Steen: "Re: Scheduling the running of a batch file"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|