Itanium911
May 31st, 2003, 04:35 AM
Hi,
I'm writing a program in VB.Net that would have to be able to shut down my pc. I know how to work with ExitWindowsEx and it workd fine for logging of, but when I want to shutdown or reboot it just won't work.
I know you need to give your program special privileges, but it just won't work. Every time I want to get the privileges connected with SeShutdownPrivileges it just returns a 0-value, so I can't get the needed privileges and I can't adjust them accordingly.
I'm wondering: has anyone got a program that WORKS and can shutdown a pc(designed in VB.Net). Please let me know, I would really appreciate it.
Thx
Itanium
I'm writing a program in VB.Net that would have to be able to shut down my pc. I know how to work with ExitWindowsEx and it workd fine for logging of, but when I want to shutdown or reboot it just won't work.
I know you need to give your program special privileges, but it just won't work. Every time I want to get the privileges connected with SeShutdownPrivileges it just returns a 0-value, so I can't get the needed privileges and I can't adjust them accordingly.
I'm wondering: has anyone got a program that WORKS and can shutdown a pc(designed in VB.Net). Please let me know, I would really appreciate it.
Thx
Itanium