Please visit the LangaList Home Page

Please note: Older issues may contain information that is now out of date


How To Subscribe and Unsubscribe is at the end of this note. Mailing List Trouble? See http://langa.com/help.htm
Questions about the advertisers? See the end of this note. Please also see legal notices at the end of this note. LangaList: ISSN 1533-1156

Please recommend the LangaList to a friend! (And maybe win a prize!)

An easier-to read formatted HTML version of this newsletter is available
<a href=" http://langa.com/newsletters/2006/2006-05-01.htm ">here</a>

The LangaList
Standard Edition

2006-05-01

A Free Email Newsletter from Fred Langa
That Helps You Get More From Your Hardware, 
Software, and Time Online

Please visit our sponsors and help keep the LangaList S.E. free!

Contents:

1) Very Cool Tweak: The OS Hidden Inside The OS
2) Fred's Deep Blush (Deleting TMP Files) Pt1
3) Fred's Deep Blush (Deleting TMP Files) Pt2
4) Fred's Deep Blush (Deleting TMP Files) Pt3
5) Bogus "No Floppy" Error
6) Recommend This Newsletter And Win!
7) Defender Glitch Fixed (?)
8) And *Another* Code Load Success Story
9) Still *More* Ghostbusting
10) New, Java-Based Free Office Suite
11) Free Personal Web Sites From Microsoft
12) Drive + Safe Deposit Box?
13) Running Out Of USB Drive Letters
14) Optional Links
15) Just For Grins

Next Issue:
2006-05-04

 

--- ( Your Clicks On Ad Links Help Keep The LangaList S.E. Free! ) ---

Make your Internet Faster!

Run PC Pitstop's Free Optimize Scan to check proper registry settings for
your connection type. Optimize tweaks the optimal registry values to get the
most from your Internet connection. Optimize also removes clutter from your
registry and hard drive to improve your overall computer performance.

Scan now!

Click: http://www.pcpitstop.com/tinylink.asp?id=211487

--------------( the above is an advertisement )--------------

 

1) Very Cool Tweak: The OS Hidden Inside The OS

Windows XP's Recovery Console is a good but very limited tool.

By default, it restricts you to working in just a few system folders, refusing you access to any other part of your hard drive. It prevents you from using "wildcards" (such as "*.exe" to represent all files ending in "exe"). It won't let you copy files to removable media such as floppies. And you're always prompted when overwriting each and any file.

Fortunately, a simple tweak that can be performed in under a minute removes all those restrictions and frees up Recovery Console to let you work anywhere on the hard drive; to access and use removable media such as floppies; to use wildcards to work on large groups of files or folders at once; and more.

With this tweak, Recovery Console becomes, in effect, a general-purpose XP DOS, serving much the same function as did DOS boot floppies for earlier versions of Windows. With the Recovery Console's limitations removed, you can then access any file or folder anywhere on your hard drive and run any of some 34 DOS-like commands.

And again, these commands will now work ANYWHERE on the hard drive--- not just in a the few folders that Recovery Console normally restricts you to.

With this tweak, the Recovery Console really does become a kind of lightweight XP DOS--a much more powerful, all-purpose mini-operating system, making it enormously more useful than otherwise.

Full info, including a how-to to implement the tweak:
http://www.informationweek.com/story/showArticle.jhtml?articleID=187000225

Click on over!

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

--- ( Your Clicks On Ad Links Help Keep The LangaList Free! ) ---

--------------( the above is an advertisement )-------------

2) Fred's Deep Blush (Deleting TMP Files) Pt1

Maybe I was lost in a "forest through the trees" problem. Maybe I just spaced out. But in any case, in "Free Tool & Demo From Fred" ( http://langa.com/newsletters/2006/2006-04-13.htm#1 ) we discussed a problem designed to (1) illustrate the general principles of automating some commands that normally resist automation; and (2) specifically, to clean up errant TMP files that were accumulating in a reader's C:\ folders.

I remembered from my batch-file programming days something called a "For...In...Do" loop, which allows for repeated execution of a command on a set of files. The skeletal form is:

     FOR %thisvariable IN (thislist) DO thiscommand

In the template above, "thiscommand" (whatever it might be) will be performed once for every item in "thislist." The %thisvariable represents a special variable that the batch processor will substitute with one item at a time from (thislist) until the end of the list is reached. In typed-in commands, that special variable is indicated with a single % sign as shown. Inside batch files, it's written with double percent signs (%%), but it's otherwise exactly the same.

Here's how it works in real life: If (thislist) is a list of files in a directory, for example, the FOR part of the command would take the file names IN (thislist), one at a time, assign them to (thisvariable) and then DO whatever command you specify on each file, in turn. Thus, the specified command will be performed once on each file in the directory, in this example.

And because the command is executed once per item in (this list), it gets past the "no wildcard" limitations of powerful commands like RD--- Remove Directory: Using a  FOR...IN...DO loop will issue one RD command per item in (thislist), with no wildcards needed.

So, when we got the reader letter asking about deleting a group of TMP files from the C:\ directory, I set about trying to make it work with a simple one-line batch command based on the FOR...IN...DO structure.

I still don't know why, but I couldn't make it work. I tried the copious help built into XP (go to Start/Run, type COMMAND on the Run line to open a command window, and type "FOR /?" (without the quotes) for several screens of help.) I tried web sites. ( http://www.google.com/search?hl=en&lr=&safe=off&q=for+in+do+batch ) I even blew the dust off a 1990 edition of "DOS Power Tools;" a massive 1300 page tome that was state of the art 16 years ago, and that covers batch programming in abundant detail. <g> The "For...In...Do" trio is covered on page 568, and my copy of the book naturally falls open to that page!

With all that, you'd think I could get the TMP deletion to work. But nothing I tried worked, and after an increasingly frustrating while, I assumed (!) I'd run into a special condition or prohibition in XP--- maybe related to working in the root folder. So, with the newsletter deadline approaching, I opted for the longer but more certain Plan B (using an external tool) which was what I published in http://langa.com/newsletters/2006/2006-04-13.htm#1 . That, at least, I could get to work, for sure; and the info there is correct, as published.

But the limitation was mine, not XP's, There indeed is a simpler easier way, via a For...In...Do command, as a number of readers gently informed me. (See next items.)

I still have no idea what my blind spot was in trying to build that command. I suppose the silver lining is that now you've seen an even wider range of approaches to solving this kind of problem, and a very real--- albeit personally embarrassing--- example of how a Plan B can still quite adequately get the job done when Plan A just won't work for whatever reason.

But I apologize for my blind spot.

Anyway, see the next items for several very slick examples of reader-crafted FOR...IN...DO loops.

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

3) Fred's Deep Blush (Deleting TMP Files) Pt2

(Continued from above item; use all the following as EXAMPLES that may have to be tweaked to work properly on your specific system.)

Fred, Rather than having to write an EXE file, you could simply use the FOR command built into XP. Two ways you could do this:
1. Use the /D flag, which tells FOR that the wildcards refer to directories:
        FOR /D %d IN (*.tmp) DO RD /Q /S %d
2. Using the file created by DIR /B, you could use the /F option:
        FOR /F %d IN (DELME.TXT) DO RD /Q /S %d
(This would work, as when the FOR command tokenizes each line, there is only one token in the file per line.) --- Steven Foust

Hi Fred,  For the user who wanted to delete all *.tmp directories -- how about this. No need for any external tools:
       C:
       cd \
       for /F "delims=" %%i in ('dir /A:D /B *.tmp') do @rd /S /Q "%%i"
All the best, Robin

Fred: Just got the 2006-4-13 Plus Edition with your lead article "Free Tool & Demo From Fred" regarding removing .tmp folders from the root of a C: drive. I think there is a simple one line DOS command which will do the trick. Try this:
       FOR /d %a IN (C:\*.tmp) DO rd %a
The FOR command loops thru all the values inside the parentheses one at a time and executes the command following the DO. Because the rd command is executed for a single folder at a time it gets around the limitation on wildcards.  The /d option after the FOR tells the FOR command to process directories. DOS Command Extensions need to be enabled for this to run, but I think they are enabled by default in Win XP. Typing FOR /? at a command line will display all the options that FOR supports. As a veteran programmer (30+ years) I understand the urge to write your own solution to a problem when the simple one-line answer is elusive. I've done it many times. You'll probably have 100 versions of this solution from all the old DOS hackers out there. Thanks for the great newsletter. ---Frank Tanzillo

Fred: Thanks as ever for the great newsletter! The Plus is definitely worth springing for! In regards to "1) Free Tool & Demo From Fred", here's a quick way to accomplish the folder deletions from the command line without having to use external programs in Windows XP:
        for /d %i in (*.tmp) do rd /s /q "%i"
This searches only for directories named *.tmp and for each one executes the "rd" command. So your sample batch file would become:
        c:
        cd \
        for /d %%i in (*.tmp) do rd /s /q "%%i"
Note that the single percent sign has to be doubled when used in a batch
file. The FOR command has become extremely useful under XP, even to the extent
that it can do simple text file parsing and variable substitution. I use it at work to scan program listings and extract certain data structure values for use in automatically constructing INF files. Anyway, just thought this might be interesting. Keep up the excellent work! *joe*

Fred: There's a much cleaner way to delete directories ending in .tmp using a batch file - and it's only one line!
     FOR /D %%F IN (*.TMP) DO RD /S /Q %%F
Fire that batch file off in the directory that has the problem directories and watch them go away.... If you try this from the command line, replace the two %%'s with just single %'s - ie   
     FOR /D %F IN (*.TMP) DO RD /S /Q %F
I find that the FOR command is one of the most powerful yet underused commands in the MS world. Love your newsletter, I've been a long time subscriber and still learn something new in every letter. ---Jim Ruby
 

Hi Fred, I know you are going to get a lot of comments and suggestions about this but I could not resist suggesting a BAT only solution because not everyone can make EXE programs.
1. Make one TXT file called delme.txt which includes only "RD /S /Q ".
2. Modify your delme.bat to be recursive and modify the DIR command:
     c:
     cd \
     :start
     if exist delme.bat del delme.bat
     if not exist *.tmp goto :notmp
     copy delme.txt delme.bat
     dir /b *.tmp >> delme.bat
     call delme.bat
     goto :start
     :notmp
     cls
    @echo No tmp folders/files found; aborting.
    @pause
    :end

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

4) Fred's Deep Blush (Deleting TMP Files) Pt3

(Continued from above item; use all the following as EXAMPLES that may have to be tweaked to work properly on your specific system.)

And this reader's solution is worth isolating because of the comments regards the use of XP's "CMD:"

Fred:

Deltmpdir.cmd
----------//----------
@echo off
Pushd c:\
for /F "usebackq delims=" %%a in (`dir *.tmp /ad/s/b`) do rd "%%a" /s/q
Popd
----------//----------

To clean up real temp dirs, something like this works swimmingly:

DelTempFiles.cmd
----------//----------
@echo off
Pushd c:\
for /F "usebackq delims=" %%a in (`dir *Temp /ad/s/b`) do (
    pushd "%%a"
    echo "%%a"
    rd . /s/q
    popd
)
popd
----------//----------

Very succinct and imminently maintainable.

Any commands that you do not know what they do, you can use the built-in
HELP command from a CMD prompt for detailed information:  (ie, HELP PUSHD,
HELP POPD, HELP FOR, HELP ECHO, HELP IF)

Note that for the past 6 years or more the CMD processor has supported
such features, including scoping and statement blocks.  Unfortunately most
people think that batch files should have an extension of .BAT.  Until
recently this meant they were processed using the COMMAND processor rather
than the CMD processor and thus were confined to the 1970's batch language
implemented in DOS's Command processor even though far more advanced
capabilities were available simply by writing NT CMD batch files rather
than legacy DOS command files. ---Keith Medcalf

Thanks, Keith. Interested readers can look up "CMD" (without the quotes) in the XP help system; or see: http://tinyurl.com/fc2tu .

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

5) Bogus "No Floppy" Error

Hi Fred! I really enjoy your newsletter. It has been of great help to me many times over.
 
My problem is this. I recently had to go into bios start mode, and now I can't figure out how to get back to the normal boot sequence. I get a black screen, listing the bios version, and stating that there was a floppy search error, and giving me the option of  pressing either the F1 or F2 button. This happens every time I boot and is very time consuming. I have a new Dell with windows XP, version 2002, service pack 2. I don't have a floppy drive! Any help you could give me would be greatly appreciated.
 
Thank you so much. ---Joseph A. Dougherty

Most BIOSes have a setting to disable the floppy seek--- where the PC searches for the floppy drive(s) at every boot. The verbiage may vary, but in an Award BIOS I have here, it's listed under "Advanced BIOS Features" and is called "Floppy Drive Seek." *DIS*abling that feature tells the PC not to bother checking the floppy on start, and saves time; and will get past error messages in systems that may not have a floppy, such as yours.

Again, the verbiage may differ from brand to brand; the setting could be in places where the boot devices are listed or prioritized, or elsewhere--- just poke around in the BIOS, looking for floppy-related startup settings.

There's usually also a "fast boot" or similarly-named option that skips many routine startup self-tests; and an error-sensitivity (sometimes called "Halt On") setting that tells the PC if you want it to halt the boot and display information about every startup error that might happen, or only selected ones, such as "no keyboard" and the like.

More:
http://www.google.com/search?hl=en&lr=&safe=off&q=BIOS+setup

And, as an aside: I use a digital camera to record the default BIOS settings of each new PC I get. That way, I know how things were set when I first got the machine; and can easily restore them, if I need to. This can be useful when the as-delivered setup differs from the "default" or "safe" settings built into the BIOS....

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

--- ( Your Clicks On Ad Links Help Keep The LangaList S.E. Free! ) ---

"Thank you for providing this service for a reasonable price.
Your information saves me hours, days and probably years of my life
having to do all of the research and trial and error myself!"
--- Lorna McCafferty

Thanks, Lorna!

The LangaList Plus! Edition is ad-free, spam-proof,
and contains even more content--- tips, tricks, advice, downloads....---
than the Standard Edition you're now reading.

Only about $1 a month!

http://langa.com/plus.htm

--------------( the above is an advertisement )--------------

6) Recommend This Newsletter And Win!

If you think the LangaList is a worthwhile read, maybe a friend would find it useful too! Just use the following link to recommend the LangaList---your friend may find a new source of useful information and you just may win one of three FREE ONE YEAR SUBSCRIPTIONS to the LangaList Plus! edition given each month. (If your name is drawn and you're already a Plus! subscriber, your current subscription will be extended by a full year.)

Check out the details at http://langa.com/recommend.htm . Thanks for recommending the LangaList--- and good luck!

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

7) Defender Glitch Fixed (?)

We described problems with "Windows Defender," the newer and renamed beta of  Microsoft Antispyware, in http://langa.com/newsletters/2006/2006-04-20.htm#4 .

Many readers--- thank you all!--- wrote in with suggestions along these lines:

Fred, hi. I am one of a *large* number of people having trouble updating Windows Defender.

But Microsoft knows there is a problem, and have actually provided a useful - if cumbersome - fix.

See:  http://support.microsoft.com/kb/915105/en-us

I've had to use this twice in order to update the program's definitions, and both times it's worked.

I hope this is of some use. (And I hope they fix the program soon!)

Enjoy your newsletter! ---M. L. Taylor

And it appears that MS has indeed fixed--- or at least updated--- the beta code. If you're still having trouble, try an uninstall, grab new download (from http://www.microsoft.com/athome/security/spyware/software/default.mspx ) and then reinstall.

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

8) And *Another* Code Load Success Story

After his site was listed in the last "Load The Code" section, this code-loader wrote:

Dear Fred, I was thrilled to see my web site http://www.meditateforyou.com/Contacts.html listed in The Langalist! I'd just noticed this morning that my hits are way up, and now I know how that happened. Thanks so much!

Do you have a home page or website? (It doesn't matter what size.) Please click over to http://langa.com/code.htm , and maybe you can join the thousands of LangaList readers who have "Loaded the Code!" (If you've already "Loaded The Code" and are wondering if your site will appear here or on the Langa.Com web site, please see http://langa.com/link.txt )

Speaking of which: Here's another eclectic sample of reader sites--- some professional, some very personal:

View A Randomly-Chosen Reader Site
http://langa.com/randomlink.htm

Manually Browse All Posted-to-Date Sites Starting At
http://langa.com/readersites.htm

David Scrimshaw's Blog
http://davidscrimshaw.blogspot.com/

Missionary Kids
http://www.mkstay.org/welcome.htm

Donron.Punt.NL
http://donron.punt.nl/

Glen Urquhart Public Hall (Scotland)
http://www.glenurquhart.info/

Libyan Blog
http://libyanit.blogspot.com/

Ladybug Creations
http://www.myladybugcreations.com/

Satrakshita
http://www.satrakshita.com/english.htm

FrauBucher: Mindful Marginalia
http://fraubucher.blogspot.com/

South Erin (NY)
http://southerin-ny.org/

Fireberg
http://www.firebergradio.com/

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

--- ( Your Clicks On Ad Links Help Keep The LangaList Free! ) ---

--------------( the above is an advertisement )-------------

9) Still *More* Ghostbusting

We've covered ways to track down various mysterious "ghost-in-the-machine" actions and sounds of late (see http://langa.com/newsletters/2006/2006-04-20.htm#3 and http://langa.com/newsletters/2006/2006-04-13.htm#3 . Here are some additional things to consider:

Fred: I'm a Plus edition subscriber and recommend you letter often.

In (3) More Ghostbusting Erich mentioned that he is hearing the Device Connect sound.  He should check his USB power management in device manager.  One of the guys in the office had a mouse that would die several times a day.  Power management was turning off the mouse.  Another brand would retain enough juice to wake itself up if there was enough vibration or you moved it.  The system would play the disconnect sound and the connect sound right behind that.

Another source of sounds like that is Enterprise Manager in SQL Server.  If you have a grid of data open for any length of time EM wants to close it to save memory.  It shows a warning dialog.. If EM does not have the focus you will hear the sound of the warning dialog but the dialog is in the background.  After a while EM just closes your grid and shows another dialog with its sound (also in the background).

E-mail is another possible source of such sounds.  At work we all leave Outlook running all the time.  It plays a "bing-bong" every time a new message arrives.  As a senior developer I see an average of 5 messages per hour on a slow day.

Another mystery source of such sounds can be nearby Mobile devices (Windows Mobile, Pocket PC, Windows CE, Palm Pilot, etc.).  When I would lay a device down on the desk my laptop would play a sound.  Pick the device up and the laptop played a different sound.  What the...?  This stopped once I turned the IR port on the device off. ---Charles Kincaid

Excellent, Charles; thanks. A couple items in there I wouldn't have thought of!

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

10, 11, 12, 13, 14) Plus! Edition Only:

Today's LangaList Plus! Edition contains about 40% more content including:

  • New, Java-Based Free Office Suite
        (plus, a GB of online storage for your files)
  • Free Personal Web Sites From Microsoft
        (they'll even pay for the domain name registration!)
  • Drive + Safe Deposit Box?
        (reader explores long-term storage options)
  • Running Out Of USB Drive Letters
        (make Windows stop assigning new drive letters)
  • Optional Links
       (just for Plus! subscribers)

The Plus! edition is only pennies per issue, and comes with a MONEY BACK
GUARANTEE from Fred. You can't lose!

Plus! Edition info: http://langa.com/plus.htm

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

--- ( Your Clicks On Ad Links Help Keep The LangaList Free! ) ---

--------------( the above is an advertisement )-------------

15) Just For Grins

Reader Dave Sutton sends along this item, which is the very embodiment of "anticlimax:" http://www.joys-of-computing.com/

Click to email this item to a friend
http://langa.com/sendit.htm

return to top of page

(Give a gift subscription to the LangaList Plus edition!
Click <a href= " http://langa.com/plus_gift.htm ">here</a>)

The LangaList is published about 72 times a year, or about 6 times a month. See you next issue, 2006-05-04

Best,

Fred
( Editor@Langa.Com )

Please recommend the LangaList to a friend! (And maybe win a prize!)

An easier-to read formatted HTML version is available in the "Current Issue" section of http://langa.com.  (The HTML version of each issue normally is available by 9AM EST [UT-5] of the issue date.) All past LangaList issues are also available at the Langa.Com site.

return to top of page


Administrivia:

UNSUBSCRIBE (instant removal!): http://langa.com/leave_langalist.htm

SUBSCRIBE (it's free!): http://langa.com/join_langalist.htm

CHANGE ADDRESS? LIST TROUBLE? HAVE QUESTIONS? OTHER PROBLEM? NEED HELP? See http://langa.com/help.htm

This newsletter is SPAM PROOF and requires two levels of subscriber confirmation before delivery begins: See http://langa.com/info.htm

About the advertisers: http://langa.com/privacy.htm#ads

Disclaimer: http://langa.com/legal.htm  In brief: All information herein is offered as-is and without warranty of any kind. Neither Langa Consulting LLC, nor its employees nor contributors are responsible for any loss, injury, or damage, direct or consequential, resulting from your choosing to use any information presented here.

This newsletter is a service of Langa Consulting LLC and is Copyright © 2006 Fred Langa / Langa Consulting LLC. All worldwide rights reserved. LangaList: ISSN 1533-1156

return to top of page


Please visit the LangaList Home Page