home *** CD-ROM | disk | FTP | other *** search
- Bill Reid's Command Line
- Frequently Asked Questions
-
- ---------------------------------------------------------------------------
- Program Operation
- ---------------------------------------------------------------------------
-
- Q: What is this program?
- A: It's a tool for helping folks who still enjoy controlling their
- computers from a command prompt, but need the applications and
- goodies only available in the Win32 GUI.
-
- Q: How does it work?
- A: Typing a command and pressing "Enter" executes it.
-
-
- Q: How do I get DOS commands to run?
- A: To launch a DOS command from within Win32, you have to preface
- it with "command /c". To get a "dir" to work, you'd enter
-
- command /c dir
-
- Q: Isn't there another way?
- A: Not in Win32. But within this application, you can substitute
- the symbol % to achieve the same effect, as
-
- %dir
-
- Q: How are long filenames handled?
- A: The same way the 'Run' command does. You need to enclose long
- filenames in double quotes in order for the program to properly
- recognize them.
-
- Ie., if you want to refer to Wordpad in your Program Files\
- Accessories folder, you'll need to specify it with the quotes
-
- "C:\Program Files\Accessories\Wordpad"
-
- Q: What about under DOS?
- A: The same way. Quotes around the long filenames, exactly as you'd
- type it at the DOS prompt. Everything after the "command /c" or "%"
- is passed verbatim to the OS's DOS interpreter.
-
- Q: What are aliases?
- A: Aliases are keywords that serve to represent a command line in
- shortened or more conveniently typed form. By associating a
- command line with an alias, you can more easily execute those
- long commands.
-
- For example, I might wish to associate 'pad' with the bulky line
- "C:\Program Files\Accessories\Wordpad.exe". From that point on,
- typing 'pad' would essentially be the same as typing the longer
- alternative.
-
- Q: Can I use partial aliases? Like alias a directory and add things
- on the end to run different things?
- A: No. Aliases are not links or anything like that. If you alias
- the word 'pad' and enter 'pad mydoc.doc' you're going to get an
- error. If enough people desire this feature, I'll look at adding
- it in.
-
- Q: Should I limit my aliases for better performance/less registry bloat?
- A: Aliases are stored in a text file in the same directory as the app.
- Of course, the more you load in memory, the more memory is required,
- but the effect is pretty minimal. You can keep an eye on the file
- aliases.cfg to make sure it's not taking up more disk space than you
- wish it to engulf.
-
- Q: How does the history support work?
- A: Anything that appears in your command history (the items that recyle
- when you use the up and down arrows or that appear in the block below
- the command line if you have the window sized large enough) appears
- there again on the next load of the program.
-
- Q: What if I don't want those items reloaded?
- A: Tough nuggies :) Actually, you can set a registry key by hand. Just
- add a string value named "History" and enter the value "1" (without the
- quotes). No more history actions.
-
- Q: What's a "permanent history" option?
- A: Basically, these items will appear in your history list no matter what.
- Even if you "Clear History" and close the app with no entries in the
- app history, these entries will come back. Guaranteed to be there.
-
- Q: How do I make some permanent history items?
- A: In the application's directory, create a text file named "permhist.cfg".
- Put any entries you wish in the file, seperating each with a carriage
- return. Like so:
-
- calc.exe
- win.ini
- %runmyapp /a /b
-
- If you're worried about your syntax being off, copy entries from the
- history.cfg file (the other history listing, auto-generated by app) to
- make sure it's workable.
-
- Q: What if I don't want permanent history items?
- A: Do as mentioned for the "no history items" above, but name the string
- value "PHistory". Setting these options according to your desires
- should give you the most flexible history saving plan possible.
-
- Q: What if I set those registry entries and changed my mind?
- A: Either delete the keys you created or set their value to "0" (without
- the quotes).
-
- Q: What is the registry?
- A: IF YOU HAVE TO ASK, YOU NEED TO STAY AWAY FROM IT! The Registry is a
- database that stores all sorts of configuration information about your
- computer. You can _seriously_ mess up your computer software with this
- if you don't know what you're doing. If you're not familiar with the
- process of editing the registry, either learn or just be satisfied with
- the default options. I won't be responsible for what happens if you go
- poking around in there changing values.
-
- Q: Uhhh, where is the program's registry entry?
- A: HKEY_CURRENT_USER\Software\VB and VBA Program Settings\BRCmdLine\Defaults.
- At least on Win95, anyway.
-
- Q: Arrggh! I was cleaning up and deleted those .cfg files!
- A: If it was history.cfg, no problem. It gets created from your app's
- actions. You'll get one session with no history, but no big deal
- otherwise. If you deleted permhist.cfg, you just need to recreate
- it if you want those items. If it was aliases.cfg - sorry, you'll
- need to redefine them through the program again.
-
- I use these text files to keep the registry entries down. That's an
- often accessed point, so I want to be a good Windows citizen and keep
- the clutter out of there so I don't slow your system down unnecessarily.
- The load time on the text files isn't really significant unless you have
- loads of history items - and I think you'd rather have the slower load
- time than a bloated registry, anyway.
-
- Q: Why don't you include hotkey support?
- A: Because I prefer to leave that up to you! This is all about choices,
- remember? Assign a hotkey to the shortcut to this application and it
- will respect it by activating any running instances. This also means
- that you can't load 2 copies of the app simultaneously.
-
- ---------------------------------------------------------------------------
- Work-arounds
- ---------------------------------------------------------------------------
-
- Q: How can I specify a working directory?
- A: Within the application, you can't. However, you can reference Win32
- shortcut files from the command line, so you could configure a Win32
- shortcut and run that from the command line. You'll find the exact
- name of the shortcut if you do a "Properties" on it.
-
- Q: My DOS command windows pop up and off before I can read them.
- A: That's because they're configured that way in a default Win95 setup.
- You can change this by modifying your DOS prompt shortcut properties
- to not "Close Window on Exit". It's probably labeled "Command" and in
- your Windows install directory.
-
-
- Q: Isn't this a lot of typing to be doing? Where's the icons, menus, etc?
- A: You're getting the idea. Some of us still feel we're more productive
- when we type. You can "GUI out" and use the Browse menu option (or
- enter 'browse' as a keyword) to click your way to a file, if necessary.
- But I won't be adding any toolbars anytime soon.
-
- Q: You hypocrite! Then why the big button on the left side of the box?!
- A: Because you need a mousable spot in order to get the thing in your
- preferred position and a spot to launch the popup config menu from. The
- only other option would be to replace the default "edit" right click
- menu on the text area, but I assume people would like to keep that
- functionality open for themselves. I don't want to cripple good Windows
- features, after all - just add what I feel like the designers left out.
- But in keeping with its philosophy, you can use the tab key to get over
- to that button without diving into mouseland.
-
- ---------------------------------------------------------------------------
- Problems
- ---------------------------------------------------------------------------
- Q: I get a "Run time error" or something like that when I try to launch the
- program or access a feature.
- A: It's a problem with your runtime libraries. The app requires the VB 5.0
- runtime libraries and the common dialog control (COMDLG32.OCX). Try to
- install a reputable set of libraries from a software distribution site
- on the Internet. It's quite easy for some beta versions to get mixed in
- with another developers' stuff and get a version on your hard drive that's
- buggy.
-
- Q: Something ape-weird happened and the app isn't appearing when I run it
- Q: The thing just won't start up right! Help!
- A: Probably the registry is not agreeing with your current setup. Maybe
- you changed screen size or color depth or something to that effect.
- Or maybe you just found a bug I didn't.
-
- The best thing to do in these situations is to remove the application's
- registry entries - it's programmed to find suitable defaults when there
- aren't any in the registry. You won't lose your aliases - they're in a
- text file in the same directory as the application. It will default up
- in a suitable location and you can reposition/recolor it again.
-
- ---------------------------------------------------------------------------
- Miscellany
- ---------------------------------------------------------------------------
-
- Q: Who wrote this?
- A: Me :)
-
- Q: How can I contact you?
- A: Via email, currently at breid@ebicom.net. You can also reference my
- wares at http://billreid.home.ml.org/ in the freeware section.
-
- Q: Uhhh. I can't seem to browse/mail there.
- A: The Internet is a changing media, and it's very possible I may have
- moved on by then. If you need to keep up with me, keep an eye on the
- shareware/freeware sites - I'll attempt to post any moves to those
- locations. But in the meantime, you'll save yourself time by bookmarking
- my page.
-
- Q: What's the deal with naming the program after yourself?
- A: Just a bit of copyright protection. I attach my name to the title of any
- title that sounds like it probably was thought of before in order to avoid
- any trademark infringement. In real life, I'm actually very humble.
-
- Q: Then why the big bitmaps of you in the app?
- A: OK, so humility isn't everything :) Basically, I do this to help other
- people with stuff and to feel accomplishment in seeing my works flourish.
- So the ego factor ticks in a little bit after all.
-
- At least it's just my mug instead of another advertisement or a "You have
- 30 days left..." sentence :)
-