mollercw
asked on
Running program as administrator
Hi
I have a program that checks your HDD's SMART values. The first thing it does, is call CreateFile to get a handle to send along to DeviceIOControl. The program works 100% for administrators, but I need it to work for users too.
I have one of two options, either find another way of getting the handle, or install my program as a service on the machine (it will run continuously in the background anyway) and give it admin rights.
Frankly, I prefer the service option. Any ideas how?
I have a program that checks your HDD's SMART values. The first thing it does, is call CreateFile to get a handle to send along to DeviceIOControl. The program works 100% for administrators, but I need it to work for users too.
I have one of two options, either find another way of getting the handle, or install my program as a service on the machine (it will run continuously in the background anyway) and give it admin rights.
Frankly, I prefer the service option. Any ideas how?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Probably the best decision, though of course this sort of thing should be much easier in vb.net!
ASKER
Thanks for the info.