StrokesPlus.net
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Sherif Aliti  
#1 Posted : Thursday, October 20, 2022 8:46:13 AM(UTC)
Sherif Aliti

Rank: Advanced Member

Reputation:

Groups: Approved
Joined: 2/16/2021(UTC)
Posts: 39
Albania
Location: Fier

Thanks: 25 times
Was thanked: 1 time(s) in 1 post(s)
How do Run an application with admin elevated privileges?

I try at verb with "runas Administrator" but not work. Anu help?


UserPostedImage

Rob  
#2 Posted : Thursday, October 20, 2022 1:44:17 PM(UTC)
Rob

Rank: Administration

Reputation:

Groups: Translators, Members, Administrators
Joined: 1/11/2018(UTC)
Posts: 1,359
United States
Location: Tampa, FL

Thanks: 28 times
Was thanked: 419 time(s) in 356 post(s)
The verb should just be runas, seems like Windows assumes that means to run as admin.
thanks 1 user thanked Rob for this useful post.
Sherif Aliti on 10/20/2022(UTC)
Sherif Aliti  
#3 Posted : Thursday, October 20, 2022 6:26:29 PM(UTC)
Sherif Aliti

Rank: Advanced Member

Reputation:

Groups: Approved
Joined: 2/16/2021(UTC)
Posts: 39
Albania
Location: Fier

Thanks: 25 times
Was thanked: 1 time(s) in 1 post(s)
Originally Posted by: Rob Go to Quoted Post
The verb should just be runas, seems like Windows assumes that means to run as admin.


but it's not running as Administrator, s there any other option?

Rob  
#4 Posted : Thursday, October 20, 2022 8:41:43 PM(UTC)
Rob

Rank: Administration

Reputation:

Groups: Translators, Members, Administrators
Joined: 1/11/2018(UTC)
Posts: 1,359
United States
Location: Tampa, FL

Thanks: 28 times
Was thanked: 419 time(s) in 356 post(s)
You might need to do something like this:
Code:
sp.RunProgram('runas', '/user:DOMAIN\\USERNAME "C:\\Windows\\Notepad.exe"', 'open', 'normal', true, false, false);
sp.Sleep(1000);
sp.SendString("mypassword");
sp.SendVKey(vk.RETURN);
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.