Opened 16 years ago

Closed 16 years ago

#369 closed Bug (Duplicate)

RunAsWait and RunAs

Reported by: anonymous Owned by:
Milestone: Component: AutoIt
Version: Severity: None
Keywords: Cc:


When launching a program using Runaswait and giving a flag value but without giving a working directory, the program won't launch. It works with Runwait.

This code does not work (@error=1)

Dim $Result
$Result = RunAsWait("user", @ComputerName, "userpwd", 1, "calc.exe","",@SW_SHOW)
IF @error <> 0 Then Msgbox(0,"Result",$Result & " " & @Error)

This code works

Dim $Result
$Result = RunAsWait("user", @ComputerName, "userpwd", 1, "calc.exe")
IF @error <> 0 Then Msgbox(0,"Result",$Result & " " & @Error)

Same problem with RunAs

So the working dir is not optional when you want to precise the flag and the only work around is to give a working directory which is accessible to the user you are using the security context

Attachments (0)

Change History (1)

comment:1 Changed 16 years ago by Valik

  • Resolution set to Duplicate
  • Status changed from new to closed

Sigh. Not a bug in AutoIt, we still fixed it anyway since user's are idiots. Couldn't you have bothered checking the tracker first? See #309 which doesn't mention the fix but the changelog for the next version will.

Closing as duplicate.

Guidelines for posting comments:

  • You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
  • In-depth discussions should take place on the forum.

For more information see the full version of the ticket guidelines here.

Add Comment

Modify Ticket

as closed The ticket will remain with no owner.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.