Jump to content

ShellExecuteWait


Recommended Posts

Hello all.

This is an easy question for you but a big wall for me

Cant get the %#¤&"¤%&" thing to do what i want

I need to perform

"c:\cosids\bin\tbadm32.exe -i >a.txt"

and

"c:\cosids\bin\tbadm32 -Cf spssaabdb r=." in folder c:\cosids\DB\SPSSAABDB

/Joshen

Edited by Joshen
Link to comment
Share on other sites

Link to comment
Share on other sites

As far as I can see, you want this?

ShellExecuteWait ("c:\cosids\bin\tbadm32.exe", "-i >a.txt")
ShellExecuteWait ("c:\cosids\bin\tbadm32", "-Cf spssaabdb r=.", "c:\cosids\DB\SPSSAABDB")
---------------------------------------------

Hmmm, i dont get what i want

Cant find the file from ShellExecuteWait ("c:\cosids\bin\tbadm32.exe", "-i >a.txt")

I think i have tried your solution, the problem might be something else.

Lets take it from the beginning

I need to run for example c:\cosids\bin\tbadm32.exe -i > c:\tmp\output.txt

so i can use the result

I have tried

$CosidsFolder = "c:\cosids"

$Command = @ComSpec & " /c " & $CosidsFolder & '\bin\tbadm32.exe '& '-i' & '>output.txt' (Cant realy get the hang of this code)

Run($Command, "", @SW_HIDE)

This works, but i need to wait for it to end and understood that ShellExecuteWait was the way to go.

What is the best way for me to get the resutl i need?

Link to comment
Share on other sites

runwait?

yes! that worked, why make it harder than nessasary.

Dont listen to bad advise, make youre own solution.... or ask the people here that know what they are talking about.

Thanks

/Joshen

Link to comment
Share on other sites

yes! that worked, why make it harder than nessasary.

Dont listen to bad advise, make youre own solution.... or ask the people here that know what they are talking about.

Thanks

/Joshen

Lol. Glad it works now :)
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...