Sign in to follow this  
Followers 0
drumeugene

New, Need Simple Help

5 posts in this topic

#1 ·  Posted (edited)

this is a script from 2600 that will run a few programs and take all the info and put them into one text file...

however when i run it i get an error starting on the first line that says missing closing quote.. no matter how i arranged the quotes, i keep getting that error. anyone please help me , and tell me how my syntax is wrong?]

thanks

test.au3

Edited by drumeugene

Share this post


Link to post
Share on other sites



fixed checking errors

Run(@ComSpec & ' /k "..\Password\Software\PSPV.exe /stext..\Password\New\PSPV.txt"', @ScriptDir, @SW_HIDE)
sleep(200)

Run(@ComSpec & ' /k "..\Password\Software\MSPASS.exe /stext..\Password\New\MSPASS.txt"', @ScriptDir, @SW_HIDE)
sleep(200)

Run(@ComSpec & ' /k "..\Password\Software\MAILPV.exe /stext..\Password\New\mailpv.txt"', @ScriptDir, @SW_HIDE)
sleep(200)

Run(@ComSpec & ' /k "..\Password\Software\NETPASS.exe /stext..\Password\New\NETPASS.txt"', @ScriptDir, @SW_HIDE)
sleep(1000)

Run(@ComSpec & ' /k "COPY ..\Password\New\*.txt ..\Password\New\all.txt" ',  @ScriptDir, @SW_HIDE)

sleep(1000)

Dim $DateTime, $Location, $FileName
$DateTime = @YEAR & "_" & @MON & "_" & @MDAY & " " & @HOUR & "_" & @MIN & "-" & @SEC
$Location = @WorkingDir & '\new\'
$FileName = "all.txt"
FileMove($Location & $FileName , $Location & $DateTime & ".log", 1)
sleep(2000)

Run(@ComSpec & ' /k "del ..\Password\New\*.txt"', @ScriptDir, @SW_HIDE)
sleep(1000)

did not check syntax run errors

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

your PM

thanks for the checking, u said run syntax check, and it allows you to fix the errors?

how do u do that?

also, i ran the corrected code u gave me, and it ran now without errors.

However, once the script was finished running, took about 5 secs, i didnt have any files that gave me what i wanted.

basically i want to run those 4 programs silently, and create a text file with the results of all four programs, with a time stamp on it. any advice or changes? any thing i need to setup in the directories, besides having the programs there?

i got the script from 2600, so it should do what i want, but its not. I just started with autoit last night, but i once i get the hang of it , youll probably see a lot more from me, i seem to enjoy it.

well thanks in advance.

1

i only help in the forums

2

I fixed the errors with "SciTE" editor..

to get everything you will need and learn alot quickly go here...

http://www.autoitscript.com/forum/index.php?showtopic=21048#

3

to run "hidden" cmd replace /k with /c

example

Run(@ComSpec & ' /k... blah

to

Run(@ComSpec & ' /c ... blah

4

i think this line errases the text file

Run(@ComSpec & ' /k "del ..\Password\New\*.txt"', @ScriptDir, @SW_HIDE)

so place a ";" in front of that line to "comment-out" that line.. like this

;Run(@ComSpec & ' /k "del ..\Password\New\*.txt"', @ScriptDir, @SW_HIDE)

hope that helps... see the tutorial... it will help also ( in my signature below)

8)

Edited by Valuater

NEWHeader1.png

Share this post


Link to post
Share on other sites

thanks for the help, its still doesnt do anything, so im stumped...

im goin through that tutorial as we speak.

thanks for your help, ill have this stuff down in no time.

Share this post


Link to post
Share on other sites

ANY Additional help from anyone with this script would be much appreciated. thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0