Jump to content

call a program and ask for paramiters - (Moved)


Recommended Posts

Hi

 

Any ideias how i can call external program like psexec tools to ask the computername that i wont to connect like this

 

run("psexec.exe2" & \\computername -u myuser cmd.exe

this sould be called my

myapp.exe computer1

Edited by Alexandre
Link to post
Share on other sites
  • Developers

Moved to the appropriate forum, as the AutoIt Example Scripts forum very clearly states:

Quote

Share your cool AutoIt scripts, UDFs and applications with others.


Do not post general support questions here, instead use the AutoIt Help and Support forums.

Moderation Team

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to post
Share on other sites
  • Developers
18 minutes ago, Alexandre said:

run("psexec.exe2" & \\computername -u myuser cmd.exe

Looks like a wrong program name and a space missing after it!

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to post
Share on other sites
  • Developers

You really need to run au3check on your script to see whether you made syntax mistakes like you have done with this line.
So I would suggest you install the full SciTE4AutoIt3 installer and simply do a run first to check your script .
That gives this error:

>Running AU3Check (3.3.14.5)  from:C:\Program Files (x86)\AutoIt3  input:D:\Development\AutoIt3\programs\test\test\test.au3
"D:\Development\AutoIt3\programs\test\test\test.au3"(3,20) : error: syntax error (illegal character)
Run("psexec.exe" & \
~~~~~~~~~~~~~~~~~~~^

Which is a clear indication you have those backslashes there without them being part of a literal string.

Jos  

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...