I am trying to write a Freeware 32-bit program that allows the user to rebbot his machine, power down, force power down, logoff, regular shutdown, and restart Windows. My problem arises when I try to use the Restart Windows options The code I'm trying follows:
CALL ExitWindowsEx(0, %EW_RESTARTWINDOWS)
This is the same calling line as listed in the the RESTART.BAS supplied with PB/DLL. When I run this part of the code WITHOUT Client for Microsoft Network or Client for Netware Network, installed, it simply doesn't work. if I put the full source code as found in RESTART.BAS in the program, it ALWAYS says that "An pplication has refused to quit.". If I don't include that error checking, the program screws up my desktop (i.e., I can no longer select icons on the desktop - I have to cold boot to resotre the staus quo). If I *do* have one of the Clients installed, it works, BUT, after Windows restarts, I get that asinine "Click here to start." message by my Start button, which I *never* get normally. Also, every time I test it with a Client installed, it ALWAYS asks me for my logon password, even though I never put a password in it. That particular dialog says that, if I don't enter a password, the prompt won't appear, again. Well, it lied. So, my questions are: how do I stop those two happenings from occurring when I have a Client installed? Is there any way to tell IF a Client is installed? If there is, I can make the suitable branches in my program, dependent on the status of an installed Client. But, even if I can do that, that still doesn't fix the aforementioned problems I have when a Client is installed.
My platform is a Dell 486SX-33 with 32MB of RAM. My OS is Windows 95 OSR-2. I have memory managers loading in my CONFIG.SYS (I need them because of my DOS-based BBS).
CALL ExitWindowsEx(0, %EW_RESTARTWINDOWS)
This is the same calling line as listed in the the RESTART.BAS supplied with PB/DLL. When I run this part of the code WITHOUT Client for Microsoft Network or Client for Netware Network, installed, it simply doesn't work. if I put the full source code as found in RESTART.BAS in the program, it ALWAYS says that "An pplication has refused to quit.". If I don't include that error checking, the program screws up my desktop (i.e., I can no longer select icons on the desktop - I have to cold boot to resotre the staus quo). If I *do* have one of the Clients installed, it works, BUT, after Windows restarts, I get that asinine "Click here to start." message by my Start button, which I *never* get normally. Also, every time I test it with a Client installed, it ALWAYS asks me for my logon password, even though I never put a password in it. That particular dialog says that, if I don't enter a password, the prompt won't appear, again. Well, it lied. So, my questions are: how do I stop those two happenings from occurring when I have a Client installed? Is there any way to tell IF a Client is installed? If there is, I can make the suitable branches in my program, dependent on the status of an installed Client. But, even if I can do that, that still doesn't fix the aforementioned problems I have when a Client is installed.
My platform is a Dell 486SX-33 with 32MB of RAM. My OS is Windows 95 OSR-2. I have memory managers loading in my CONFIG.SYS (I need them because of my DOS-based BBS).
Comment