mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Feb 2013
Posts: 6
L
Liath Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
L
Joined: Feb 2013
Posts: 6
Hello Guys,

is there any way to run the cmd.exe with admin privileges in a script?


Joined: Jun 2007
Posts: 933
5
Hoopy frood
Offline
Hoopy frood
5
Joined: Jun 2007
Posts: 933
My first though here is if that were (easily) possible then that would defeat the entire purpose of UAC.

Joined: Feb 2013
Posts: 6
L
Liath Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
L
Joined: Feb 2013
Posts: 6
it is easy, you only have to run mirc as an administrator...

Joined: Jul 2006
Posts: 4,150
W
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,150
There is a way but you would need to enter the admin pass manually, you cannot automate anything with this.


#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Joined: Feb 2013
Posts: 6
L
Liath Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
L
Joined: Feb 2013
Posts: 6
sure, it works now...

i need the info to get gameserverstats via qstat

this line run cmd.exe and qstat.exe and write the info to data.txt

Code:
run cmd.exe /q /c c:\qstat.exe -sort pF -P -u -ne -xml -q2m master.corservers.com > c:\data.txt


you only have to start mirc with administrator privileges and it will work correct

the problem ist solved for me smile


Link Copied to Clipboard