How Can a File "Run as Adminstrator"

Neferas

New member
Joined
Oct 9, 2008
Messages
4
Programming Experience
1-3
Hello again,

Can anyone tell me how can I run or execute a file as adminstrator from VB.NET code. I've tried to run a setup .exe file from VB.NET code but I always need to pass "Adminstrator" permission by click "Continue" manually. Therefore, how can I write code in VB.NET to break through the Adminstrator.

Thanks!
Neferas
 

JohnH

VB.NET Forum Moderator
Staff member
Joined
Dec 17, 2005
Messages
15,540
Location
Norway
Programming Experience
10+
Process.Start() method has parameters for username and password, so you can supply credentials for an admin account.
 

Neferas

New member
Joined
Oct 9, 2008
Messages
4
Programming Experience
1-3
Thank you! Let me try it. I'll tell you the result.

However, I wonder that how can I know other computer Admin username and password?! What I mean is that I want to create a program that run a setup file without any permission for every PC.
 
Top Bottom