Jump to content
Sign in to follow this  
eric M

run($cmd) not good after runasset !

Recommended Posts

eric M

Hi,

When I use the "run" fonction only, I can use variable like run($cmd).

If I put a "runasset" before (to use user and password) the "run($cmd)" not work anymore.

Autoit tell me that "$cmd" is not correct ("incorrect directorie").

Can you help...

Edited by eric M

Share this post


Link to post
Share on other sites
AlmarM

Can u give me the source?? (The script :P)

Because I think you have:

Run("$cmd")

Is that not the case? Just give the source


Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Share this post


Link to post
Share on other sites
eric M

post-17204-1195205474_thumb.jpg

Can u give me the source?? (The script :P)

Because I think you have:

Run("$cmd")

Is that not the case? Just give the source

Hi AlmarM,

here is the source code :

$cmd=@ComSpec & " /k help | more"

RunAsSet("user", "domain", "password",0)

Run($cmd)

RunAsSet()

This code not run :

Y:\Mes Documents\test.au3 (4) : ==> Unable to execute the external program.:

Run($cmd)

Le nom de répertoire est incorrect.

If I do a Run($cmd) only, its all right :

$cmd=@ComSpec & " /k help | more"

;RunAsSet("user", "domain", "password",0)

Run($cmd)

;RunAsSet()

(see print screen)

Share this post


Link to post
Share on other sites
Danny35d

Run() Try adding the working directory.

Run($cmd, @TempDir)


AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line

Share this post


Link to post
Share on other sites
eric M

Run() Try adding the working directory.

Run($cmd, @TempDir)

Hi Danny35d,

Its all right after adding @tempdir...

Thanks to all of you for this help.

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  

×