Run as Administrator works, runas command doesn´t


Joined
Jun 13, 2020
Messages
3
Reaction score
1
Hi at all,

I hope my english is good enought to explain my problem to you.

I have a Win 10 PC and there are 2 Accounts on it, Admin and Employees. The Pc is going to be for the cash counter in a Bar.
So Employees shouldn´t have rights to change the system at all.

The Programm for the Cashcounter needs admin rights.
If I start by Contextmenu "run as administrator" I need to promt the admin Password and it works great.

unfortunately i can´t give the admin pw to the employees of course. So I need an option to start that Program with admin rights or as admin without needing to type the pw.

the runas.exe should do the trick, but when I start the programm - It dumbs with the first click. It starts as admin but wont run. So there might be a difference in using Contextmenu "run as administrator" and the command in the .ink-file:

runas /profile /savecred /user:Admin "C:\Program Files (x86)\Cashcounter\cashcounter.exe"

Does anyone know why or even better, does anyone know how to get the Programm to run as admin without needing to type in the Password.

Thanks in advance and best regards
Richarde
 
Ad

Advertisements

Joined
Jun 13, 2020
Messages
3
Reaction score
1
Hey and thanks for your reply. unfortunately this doesn´t solve the Problem.
 
Joined
Mar 7, 2020
Messages
178
Reaction score
20
I am having that problem myself, and at the moment exchanging script with members on this site.
 
Joined
Jan 27, 2016
Messages
792
Reaction score
78
I have ask, and the best i can find, you need two (same programs) admin to modify, then take the modified portion, set to read only as admin. copy to User program and it can only be ran - used but not modified. due to it needs Admin Rights.
Im not sure if i can explain, so you understand.
1. main program (run as Admin only)
1a. set to read only the part which Contextmenu is set READONLY by Admin (contained in the properties permission setting)
2. is a copy of Admin only removed. and set to run in READ ONLY.
sample of Admin and users setting in Properties.
1592143001860.png
1592143050382.png
 
Ad

Advertisements

Joined
Jun 13, 2020
Messages
3
Reaction score
1
Thanks everybody. I found a solution which i like to share:

The PC had 2 User Accounts:
- Admin_Club (Admin)
- User_CC (normal User)

What i did is:
- I acitvated the Standard Administrator Account (which is a normal Admin but works without UAC)
you can achive this by starting the cmd as an admin and put in net user administrator * /active:yes

- I installed the Programm I need with admin rights as Administrator
- I created a short cut for the User_CC but edited it as following:

runas /profile /savecred /user:Administrator „C:\Programme (X86)\Cashcounter\cashcounter.exe"

This was the only way it worked for me.
Same Procedure with the other Admin Account didn´t Work.
A Solution via the Task-Scheduler didn´t Work as Well, but might work if I made it like described above (i used the other admin so it didn`t work)

I hope this helps everybody with the same Problem - Contact me if you stuck and need further Help at some steps.

best regards
Richarde
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top