The reason I wrote it is because I have a problem with my USB controllers that causes an issue with the bignum plugin after resuming from standby. I wrote a script that runs just before the computer goes into stanby that kills LCD Smartie with the taskkill command, but some other plugins (mce_dll) don't work correctly if I kill LCD Smartie with the taskkill command, so I wrote this little program that gracefully closes another program, similar to clicking the red X at the top right-hand corner of a window.
It can be used to close any Windows program, including LCD Smartie.
Here's how it works:
CloseProg.exe <parameter1>
The parameter can be one of the following:
"WinItemize" - This will create a text file with a list of all open windows in your session. It will then open the file in Notepad. The file will be in your My Documents folder and will be named CloseProg.txt. Make sure to turn off word wrap when you view the file because some window names are quite long and it will be confusing to look at it when they wrap.
Example:
CloseProg.exe WinItemize
Once you figure out the window name you want to close, run the program like this:
CloseProg.exe "Window Name"
Make sure to put the parameter in quotes if your Window Name contains any spaces or special characters that the cmd.exe program will interpret as a delimiter. The Window Name is CASE SENSITIVE and can be a partial window name as follows:
- "Some Partial Name" will match any window that BEGINS with the text in your string.
- "Exact Window Name~" with a tilde at the end will match any window that has EXACTLY the title you specified.
- "~Partial Name~" with a tilde at both ends will match any window that ENDS with your string.
- "~Partial Name" with a tilde at the beginning will match any window that CONTAINS your string.
Example:
CloseProg.exe "LCD Smartie"
I don't see a way to attach a file here, so I put it on Google Docs.
Here's the link:
https://docs.google.com/leaf?id=0B9v3S7 ... 2&hl=en_US