Closing multiple instances

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
User avatar
CWBillow
Posts: 110
Joined: Thu Nov 06, 2003 11:59 pm
Location: Chula Vista California
Contact:

Closing multiple instances

Post by CWBillow »

If I have TextPad configured to NOT allow multiple instances, then, even if I am closing several documents, I only have to confirm the close once.

If I am allowing multiple instances, is there a way to accomplish the same thing -- to close all instances at one time?

Regards,
Chuck Billow
ben_josephs
Posts: 2464
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

Try this from the command line:

Code: Select all

taskkill /im TextPad.exe
Or create a .bat file with that line in it and run that.

Or create a TextPad tool:
Command: cmd
Parameters: /c taskkill /im TextPad.exe

[X] Run minimized
[ ] Capture output [i.e., not selected]
[X] Close DOS window on exit
and run that.
User avatar
CWBillow
Posts: 110
Joined: Thu Nov 06, 2003 11:59 pm
Location: Chula Vista California
Contact:

Post by CWBillow »

New to me...How do I create a tool?

Regards,
Chuck Billow
ben_josephs
Posts: 2464
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

Did you look in the help, under
How to... | Customize Settings | Tools Menu
?
miked
Posts: 68
Joined: Tue Feb 27, 2007 11:17 am

Post by miked »

That's really useful, thanks Ben. I often run multiple instances. I would never have thought of doing it that way. I had to drop the /c from the parameters. I've added the tool to my menu bar.

Chuck: If you haven't figured it out yet then:
Configure/Preferences/Tools
Drop down the add box top right and select DOS command
Put taskkill /im TextPad.exe in the entry box.
Hit Apply which should add it to the + list under the tools on the left side of preferences. Hit the + to expand the list and select the new tool.
Change the options to run minimized and don't capture output and close DOS window on exit.
Rename the tool if you want by going back to Configure/Preferences/Tools and clicking on it in the list in the middle of the dialogue under tools.
ben_josephs
Posts: 2464
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

miked: Thanks for pointing out the issue with /c.

If you add the tool with Add | DOS Command... you should not include /c.
If you add the tool with Add | Program... and explicitly specify the command cmd you should include /c.
Post Reply