Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Basic Help with XP Command-line utilities  (Read 19663 times)

0 Members and 1 Guest are viewing this topic.

jayell

    Topic Starter


    Rookie

    Basic Help with XP Command-line utilities
    « on: January 22, 2010, 09:55:57 AM »
    Hi!  Is there someone who wouldn't mind helping me with detailed instructions in running small command-line utilities.  If this isn't the right place for this post, would you re-direct me, please.

    patio

    • Moderator


    • Genius
    • Maud' Dib
    • Thanked: 1769
      • Yes
    • Experience: Beginner
    • OS: Windows 7
    Re: Basic Help with XP Command-line utilities
    « Reply #1 on: January 22, 2010, 12:11:05 PM »
    " Anyone who goes to a psychiatrist should have his head examined. "

    jayell

      Topic Starter


      Rookie

      Re: Basic Help with XP Command-line utilities
      « Reply #2 on: January 22, 2010, 12:39:32 PM »
      Thanks for the suggestion.  I didn't want to make my post too lengthy until I found out if this is the right place to get some help on this subject.  I've been through tons of these Basic User's guides in the last few days but there is also the possibility I might be experiencing a problem with settings or something. 

      I have several small, portable CL apps (like MBRWiz consisting of .exe and .txt ReadMe) that don't seem to function as simply as the guides say they will.  Specifically, I need to find out what I need to do to get the switches to function, of which there are, usually, several.  The only way, so far, that I even get to the options screen is by dragging the .exe into the XP cmd window at the prompt. 

      I've already been through several hoops on another forum like using Path Variables (didn't work for me).  My info, so far, says that isn't necessary to run these, anyway.  At least here, attachments are allowed, which would have made communications there a whole lot less confusing.  Are you game to walk through the sequence with me? 

      Treval



        Hopeful

        Thanked: 14
        Re: Basic Help with XP Command-line utilities
        « Reply #3 on: January 22, 2010, 12:52:14 PM »
        *censored*? Did someone delete my previous post on here?

        jayell

          Topic Starter


          Rookie

          Re: Basic Help with XP Command-line utilities
          « Reply #4 on: January 22, 2010, 01:30:14 PM »
          Update - I'm able to open these programs in the Run utility now through Environment Variables but everything else in my post still applies: no success with switches once inside the cmd window.  Still having this problem with option screen flashing, then disappearing.

          Dusty



            Egghead

          • I could if she would, but she won't so I don't.
          • Thanked: 75
          • Experience: Beginner
          • OS: Windows XP
          Re: Basic Help with XP Command-line utilities
          « Reply #5 on: January 22, 2010, 01:39:23 PM »
          Jayell - perhaps you could start by reading this and returning with some info.

          And Welcome to the CH forums where a screenshot is worth a lot of words.

          One good deed is worth more than a year of good intentions.

          jayell

            Topic Starter


            Rookie

            Re: Basic Help with XP Command-line utilities
            « Reply #6 on: January 22, 2010, 09:36:34 PM »
            Read the Rules and tried a search (tough to put a term to this problem) when I signed up.  I just added some info about this machine - is that the info you're after?

            Dusty



              Egghead

            • I could if she would, but she won't so I don't.
            • Thanked: 75
            • Experience: Beginner
            • OS: Windows XP
            Re: Basic Help with XP Command-line utilities
            « Reply #7 on: January 23, 2010, 01:12:18 AM »
            Thanks for that info.  I ran MBRWiz on both XP HE and Pro (x32) from the Command Line and from within a batch script and found no problems with the prog recognizing switches.

            Quote
            (like MBRWiz consisting of .exe and .txt ReadMe)
             
            I didn't find a .txt ReadMe file, the downloaded .zip file contained mbrwiz which seems to be headed in the direction of Linux, MBRWiz.exe for NT, MBRWizd.exe for Win ME/98 and MBRWiz.html which is a user guide.  Perhaps I got the wrong download?

            So, sorry, cannot assist as cannot create your problem on my XP systems, perhaps another member will be able to assist..

            Quote
            The only way, so far, that I even get to the options screen is by dragging the .exe into the XP cmd window at the prompt. 

            Edit:  Oops, I re-read your post and now think that I misunderstood your problem.

            Try this:
            Start>Run and enter cmd in the dialog box then hit OK.  This should open a Command Prompt window.  At the command prompt enter MBRWiz and the MBRWiz options will be displayed. (Provided, of course, that MBRWiz.exe is somewhere in your path).

            Did you try this already?

            Good luck.

            « Last Edit: January 23, 2010, 01:31:55 AM by Dusty »
            One good deed is worth more than a year of good intentions.

            Salmon Trout

            • Guest
            Re: Basic Help with XP Command-line utilities
            « Reply #8 on: January 23, 2010, 02:41:45 AM »
            Try this:
            Start>Run and enter cmd in the dialog box then hit OK.  This should open a Command Prompt window.  At the command prompt enter MBRWiz and the MBRWiz options will be displayed. (Provided, of course, that MBRWiz.exe is somewhere in your path).

            Alternatively, create a folder, put the MBRwiz.exe into it, then open a command window (e.g. by typing cmd in the Start Menu "run" box), then make that folder the current one, then you can type mbrwiz /? at the prompt and see the options, or you can just simply go here

            http://mbrwizard.com/reference.php

            Many command line programs (and most built in commands) obey the /? convention.

            jayell, it sounds to me that this is the information you seek, that is, how generically to run command line utilities and view their options and how to supply switches to the programs?



            Dusty



              Egghead

            • I could if she would, but she won't so I don't.
            • Thanked: 75
            • Experience: Beginner
            • OS: Windows XP
            Re: Basic Help with XP Command-line utilities
            « Reply #9 on: January 23, 2010, 03:22:04 AM »
            Or - create a desktop shortcut with:

            Target as: %windir%\system32\cmd.exe /k mbrwiz

            Start in: C:\

            Run: Maximized

            One good deed is worth more than a year of good intentions.

            jayell

              Topic Starter


              Rookie

              Re: Basic Help with XP Command-line utilities
              « Reply #10 on: January 23, 2010, 10:14:43 AM »
              Okay, first @ Dusty:  Thanks for helping.  You tried MBRWiz - that's good, tells me it does as expected with you.  I'd be interested in the steps you used next to activate one of the switches - say, </List> where it will give you a list of MBR entries.  I think that's where the roadblock is for me.

              I should mention that, currently, the path to MBRWiz is C:\Utility\MBRWiz.exe per a suggestion to keep the path simple.  There are several other small, CLI exes in there, too.

              Probably, the best thing would be for us to just forget the whole environment variable thing for the moment - simply dragging the exe to the command cursor gives the best results right now.  These aren't apps that'll be used very often.  Command is not something I see myself ever needing much.  Read: no old DOS apps or games, no scripts, no batch etc.  This started purely out of interest - thought I'd pursue why double-clicking these kind of exes gave such unexpected results.

              So why MBRWiz?? It's just an example.  I resized a partition recently (system, unfortunately) with a program that corrupted the partition tables and XP wouldn't boot.  I was able to correct that with another nice little app but now I thought that it was important to know more about the MBR/partition tables than I did.

              But here we are, back at XP command prompt, I've dragged MBRWiz.exe to the prompt, it opens the list of options..."Press any key for remaining options", after displaying next options, I'm sitting at a prompt that's at the end of <C:\Documents and Settings\UserName.

              Now, here's where cmd baffles me: am I already "outside" of MBRWiz "program"?  What's next to command a switch to activate?  If it's something simple, like enter "MBRWiz /List", I tried that days ago, got the "MBRWiz is not recognized..."

              @Salmon Trout:  Thanks for offering your assistance, too.  Sorry, didn't understand the "make that folder the current one" term in your instruction.

              As far as the provided link, yeah, been there.  The info there was what piqued my interest in the utility at the start.  The switches listed there are the ones I'm referring to here.  Just can't make them work.

              @ Dusty - your next post: are those instructions dependant at all on where MBRWiz is?  It looks as though MBRWiz.exe would have to be in the system32 folder.  Have I got that right?  Anyway, followed your instructions, got a nice, big cmd window flashing at C:\WINDOWS with a mbrwiz title bar.  Nothing worked from there.  Tried again with a copy of MBRWiz.exe in the system32 folder, typed <MBRWiz /List> and EUREKA!  Finally!  It's taken a long time to get to this point.  If there are other methods, I don't need 'em.

              This seems to be a reasonably simple way to do this - odd that no one's mentioned it up to now.  None of the tutorials that I went through mentioned this method.  It seems that the location of the exe is of prime importance.  I spent a lot of time on "paths" in Environment Variables and AppPaths in the registry - all great info but still, the switches wouldn't work.  And, as it turns out, I was entering them just as I did now.  I still don't know what that was all about.  Doesn't matter now. 

              Thank you, thank you.  I'll still be interested in any comments you'd care to make.

              Dusty



                Egghead

              • I could if she would, but she won't so I don't.
              • Thanked: 75
              • Experience: Beginner
              • OS: Windows XP
              Re: Basic Help with XP Command-line utilities
              « Reply #11 on: January 23, 2010, 12:45:43 PM »
              Quote
              It seems that the location of the exe is of prime importance.

              Yes, when the name of a file is entered a list of locations is searched for that file and, if found, it will be opened by the suitably assigned program.  The locations are stored in the Path environment variable.  So it follows that the required file can reside in any of the locations specified, not just System32, I put MBRWiz in C:\ but could have copied it to C:\Windows, C:\Bat, C:\Program Files, C:\System32 or any other path which I include in the Path variable.   

              If the file is not in the Path it can be opened by entering the full path at the Command Prompt e.g. C:\utility\MBRWiz to open Cmd.exe, run MBRWiz (displaying the options) and wait for other commands to be entered.  When I unzipped MBRWiz I put it into an Unzipped files folder so to run it from there, at the Command Prompt I would enter:

              "D:\My Downloads\Unzipped\MBRWiz\mbrwiz.exe"

              As you will know the .exe extension can be omitted.  But it's a heck of a lot easier to run it from one of the locations in Path.

              Hope we've been of some help to you.  We'll be around if you have other queries.


              One good deed is worth more than a year of good intentions.

              Salmon Trout

              • Guest
              Re: Basic Help with XP Command-line utilities
              « Reply #12 on: January 23, 2010, 12:52:16 PM »
              Many people create folders specifically for batch files, third party utilities etc and add them to the PATH variable.

              Also it is handy to have "open Command window here" as a right click option in Windows Explorer.

              jayell

                Topic Starter


                Rookie

                Re: Basic Help with XP Command-line utilities
                « Reply #13 on: January 23, 2010, 02:02:09 PM »
                Jeez, Dusty, I really hate to muddy the waters now that we've finally got somewhere but I have to point out, again, that as I stated in my last post, these apps in C:\Utilities\ will not open the way you're describing.  Although I'm able to get the option screen only if I drag the exe from C:\Utility to the cursor in cmd, the switches will not function. But thanks to you, if I'll just pop the exe into the system32 folder, I can operate the switches when the app opens!  Doesn't make sense??  You're telling me!

                I put MBRWiz in C:\ but could have copied it to C:\Windows, C:\Bat, C:\Program Files, C:\System32 or any other path which I include in the Path variable.

                I mean, did you have to enter each path somewhere for those other optional ways of opening MBRWiz?  No matter where I put it, it only works from the system32 folder so far.

                If the file is not in the Path it can be opened by entering the full path at the Command Prompt e.g. C:\utility\MBRWiz to open Cmd.exe, run MBRWiz (displaying the options) and wait for other commands to be entered.

                "D:\My Downloads\Unzipped\MBRWiz\mbrwiz.exe"  


                Yup.  Did that.  Dragging the exe there does that exactly.  Press "Enter", get the options listed but no switch action though.  As soon as I enter the switch I get the "MbrFix (or whatever util I try from C:\Utilities folder) is not recognized bla-bla-bla".

                So far, no one is willing to entertain the notion that, maybe, it's not that I'm lousy at following directions, but could something be not functioning the way that it should be?  Really, this can't possibly be this complicated, can it?

                I know, I know - take your little shortcut-to-system32-folder victory, shut up and say good-bye. :-)

                Salmon Trout

                • Guest
                Re: Basic Help with XP Command-line utilities
                « Reply #14 on: January 23, 2010, 02:09:19 PM »
                So far, no one is willing to entertain the notion that, maybe, it's not that I'm lousy at following directions, but could something be not functioning the way that it should be?  Really, this can't possibly be this complicated, can it?

                jayell, it sounds like you are misunderstanding a rather fundamental aspect of command line utilities. You have to operate them from the command line, in the way that they were designed to be operated. You can get them to do something, sure, if you drag the executable's icon into a command window, but this is not the way they are meant to be used. You have been given advice that you appear to have ignored.

                I get the impression that you think that the problem lies elsewhere than in yourself... you should perhaps reflect that you may be mistaken in that...