Hello,
I encounter a problem, I launch "Ranorex Studio" as administrator because I need to activate the "Debug" mode.
When, by script, I run "cmd" via System.Diagnostics.Process.Start to mount a network drive (useful for the application to test), this one launches as administrator and my drive is mounted but not visible in my drive list.
If I run "cmd" as administrator, the "net use" returns my drive.
If I run "cmd" without privilege, the "net use" does not return my drive.
How can I launch "cmd" without privileges when "Ranorex studio" is launched as administrator and my session account is an administrator account?
command CMD
Re: command CMD
Hi,
I'm slightly confused here?
If Ranorex is started as admin, then any command launched from it (including CMD), should by started with admin privileges as well. But then you mention this...
I'm slightly confused here?

But then you asking how to launch CMD as non-admin?...If I run "cmd" without privilege, the "net use" does not return my drive.
So when exactly CMD works as expected? With or without admin privileges?How can I launch "cmd" without privileges
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration
- Julien Diot
- Posts: 51
- Joined: Wed Feb 20, 2019 4:25 pm
- Location: Amiens (FR)
Re: command CMD
Thank you for your answer.
The CMD command works correctly without administrator privileges.
If I run "cmd" as administrator off ranorex, the "net use" returns my drive create in ranorex (with privileges admin) but this drive is not visible in local drivers.
If I run "cmd" without privilege off ranorex, the "net use" does not return my drive create in ranorex (with privileges admin).
For this to work, I'd have to run the "net use" command by running CMD without admin privileges in ranorex.
The CMD command works correctly without administrator privileges.
If I run "cmd" as administrator off ranorex, the "net use" returns my drive create in ranorex (with privileges admin) but this drive is not visible in local drivers.
If I run "cmd" without privilege off ranorex, the "net use" does not return my drive create in ranorex (with privileges admin).
For this to work, I'd have to run the "net use" command by running CMD without admin privileges in ranorex.
- Julien Diot
- Posts: 51
- Joined: Wed Feb 20, 2019 4:25 pm
- Location: Amiens (FR)
Re: command CMD
Off ranorex,
If I do a net use x: \\ShareFolder" by running "CMD" with admin privileges, my drive is created but not visible in local drives, the mapping is not accessible. Not OK.
If I do a "net use x: \\ShareFolder" by running "CMD" without admin privileges, my drive is created and visible in local drives, the mapping is accessible. Ok.
So I would like to be able to run "CMD" without admin privileges even if "Ranorex" is run as admin.
If I do a net use x: \\ShareFolder" by running "CMD" with admin privileges, my drive is created but not visible in local drives, the mapping is not accessible. Not OK.
If I do a "net use x: \\ShareFolder" by running "CMD" without admin privileges, my drive is created and visible in local drives, the mapping is accessible. Ok.
So I would like to be able to run "CMD" without admin privileges even if "Ranorex" is run as admin.
Re: command CMD
I see. Well, I'm afraid, there is no an easy and one step solution for this. Check for example this discussion:
https://stackoverflow.com/questions/117 ... ld-process
https://stackoverflow.com/questions/117 ... ld-process
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration
- Julien Diot
- Posts: 51
- Joined: Wed Feb 20, 2019 4:25 pm
- Location: Amiens (FR)
Re: command CMD
Thank you. I'm gonna go read this.