Since the DQSD help window already has an interface to select/unselect searches, I thought it might be nice to use that to drive the search removal process instead of a website that Monty has to maintain (although the delete by category is handy). Attached is a batch file (included in-line, since sourceforge wisely blocks .bat files. It should be self-explanatory - all it does is read the disabledsearches.txt file created by the help window and from that file executes a mvoe instruction for each corresponding .XML file. This works under XP and any other variant that supports the "FOR /F" batch command (to check, type "for /?" at the command line to see if you get help on FOR /F).

------------------
::Removesearches - by Phil Albert for use with DQSD (www.dqsd.net).
::This batch file renames (actually uses the DOS "move" command
::because "rename" chokes if the target already exists, and it will
::if you run this a second time, such as after an update.

::Run this from anywhere.  An anal programmer might rewrite this
::properly so that the batch file does not alter the current
::dir and uses more constants, so I give anyone permission to
::do anything with this except blame me for anything.
::In other words" "caveat ??" (is there latin for "end-user"?)

::change this if you have a different location for search files.
C:
cd "C:\Program Files\Quick Search Deskbar\searches"

::The pauses are so you can see how badly my batch file messed up.
::Note that the "FOR /F" command is an extended command.  I know
::not what that means, but it is part of my standard XP install.
pause

::If you use the help windows built into DQSD to uncheck searches
::you don't want, it will create a file disabledsearches.txt listing
::the disabled searches. This DOS command renames each of those.
FOR /F %%s IN (..\disabledsearches.txt) DO move %%s.xml %%s.xml.removed-search.txt
pause
------------------


--
Phil Albert, full-time patent attorney and philosopher, part-time car thief
ICBMNET: 37 deg, 25', 30" N, 126 deg, 13', 34" W
Voicenet: (415) 576-0200 bizcardnet: Townsend & Townsend & Crew LLP
Internet: palbert 'at' alumni 'dot' caltech 'dot' edu or whatever alias I am using today.





------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click _______________________________________________ To unsubscribe visit: https://lists.sourceforge.net/lists/listinfo/dqsd-users [EMAIL PROTECTED] http://sourceforge.net/mailarchive/forum.php?forum_id=8601

Reply via email to