PC Review


Reply
Thread Tools Rate Thread

Commandline history randomness :-(

 
 
R.Wieser
Guest
Posts: n/a
 
      4th Feb 2011
Hello All,

I've got a problem with XP's command-prompts (cmd.exe) commandline-history
behaviour:

Quite often when I press the "up" arrow (to go back to the previously typed
commandline, or, on a next key press, to the one above it) I find myself ...
somewhere in that list, but definitily *not* at the bottom of it.

This is disconcerting, as it can land me on a command which nullifies all
the work I've previously done on a file (by *again* copying an origional
file to my working-folder, thereby erasing the work I just did on the copy).

My question therefore is: can I tell the commandline-history to *allways* go
to the bottom of its history-list (and not display any form of a to me
counter-productive 'intelligence') ?

If that is not possible, how do I disable that commandline-history (without
blocking other programs to take its place -- Can't seem to get an old
version (W98se) of DosKey.com running ...).

Regards,
Rudy Wieser



 
Reply With Quote
 
 
 
 
John Wunderlich
Guest
Posts: n/a
 
      6th Feb 2011
"R.Wieser" <(E-Mail Removed)> wrote in
news:4d4bd16e$0$34849$(E-Mail Removed):

> Hello All,
>
> I've got a problem with XP's command-prompts (cmd.exe)
> commandline-history behaviour:
>
> Quite often when I press the "up" arrow (to go back to the
> previously typed commandline, or, on a next key press, to the one
> above it) I find myself ... somewhere in that list, but definitily
> *not* at the bottom of it.
>
> This is disconcerting, as it can land me on a command which
> nullifies all the work I've previously done on a file (by *again*
> copying an origional file to my working-folder, thereby erasing
> the work I just did on the copy).


The up-arrow will take you to the last command that you executed. If
the last command that you executed was generated by hitting the up-
arrow to go to a previous command and then you modify that command,
then the last command executed would be the last command in the
history list. OTOH, if you go to a command in history with the up-
arrow and execute it unaltered, then the last command you executed
was that line in history and subsequent up-down arrows will be
relative to that point.


> My question therefore is: can I tell the commandline-history to
> *allways* go to the bottom of its history-list (and not display
> any form of a to me counter-productive 'intelligence') ?


Sure, just press Page-Down before pressing the up-arrow.

> If that is not possible, how do I disable that commandline-history
> (without blocking other programs to take its place -- Can't seem
> to get an old version (W98se) of DosKey.com running ...).


You can change the length of the history buffer to "1".
For example:

C:\>doskey /reinstall /listsize=1

Keep in mind that after Windows 98 & ME, the command line window is
not really a DOS window but a program emulating it.

Some good reading that you might be interested in:

"The Windows NT Command Shell"
< http://technet.microsoft.com/en-us/l.../cc723564.aspx >

HTH,
John
 
Reply With Quote
 
glee
Guest
Posts: n/a
 
      6th Feb 2011
"R.Wieser" <(E-Mail Removed)> wrote in message
news:4d4bd16e$0$34849$(E-Mail Removed)...
> snip
> Can't seem to get an old
> version (W98se) of DosKey.com running ...


Windows XP does not use Doskey.com from Win98, it uses Doskey.exe, in
the system32 folder.

You should not need to use Doskey, since the behavior you want is built
into the command prompt in XP.
--
Glen Ventura
MS MVP Oct. 2002 - Sept. 2009
CompTIA A+
http://dts-l.net/

 
Reply With Quote
 
R.Wieser
Guest
Posts: n/a
 
      6th Feb 2011
Hello Glee,

> You should not need to use Doskey, since the behavior you
> want is built into the command prompt in XP.


My apologies if I was not clear, but the reason I posted is that that
program does *NOT* exhibit the behaviour I expect from it.

As it does not I would like either to know of a way to make it behave
consistently, or to be able to replace it. If its really a part of the
cmd.exe either of the above might be difficult to do.

Regards,
Rudy Wieser

-- Origional message:
glee <(E-Mail Removed)> schreef in berichtnieuws
iim665$b8v$(E-Mail Removed)...
> "R.Wieser" <(E-Mail Removed)> wrote in message
> news:4d4bd16e$0$34849$(E-Mail Removed)...
> > snip
> > Can't seem to get an old
> > version (W98se) of DosKey.com running ...

>
> Windows XP does not use Doskey.com from Win98, it uses Doskey.exe, in
> the system32 folder.
>
> You should not need to use Doskey, since the behavior you want is built
> into the command prompt in XP.
> --
> Glen Ventura
> MS MVP Oct. 2002 - Sept. 2009
> CompTIA A+
> http://dts-l.net/
>



 
Reply With Quote
 
R.Wieser
Guest
Posts: n/a
 
      6th Feb 2011
Hello John,

> OTOH, if you go to a command in history with the up-
> arrow and execute it unaltered, then the last command you executed
> was that line in history and subsequent up-down arrows will be
> relative to that point.


I just tested that (yeah, really want to get to the bottom of this :-) ) and
looking at the F7 "last commands" list it looks you're right. In it the
repeated comand is highlighted.

Funny though: its also displayed at the bottom as the last executed command.

But that does not take away the problem I have with it (its seeming
randomness) to have the selection-point to *allways* start at the bottom, no
exception. Any idea how ?

> Sure, just press Page-Down before pressing the up-arrow.


And no, that is not my idea of a/the solution, sorry.

> You can change the length of the history buffer to "1".
> For example:
>
> C:\>doskey /reinstall /listsize=1


That cure would be worse than the disease I'm afraid, I'm really using that
command-history. Any chance that it allows itself to be un-installed (or
simply not installed/started in the first place) ?

And thanks for the clarification.

Regards,
Rudy Wieser


-- Origional message:
John Wunderlich <(E-Mail Removed)> schreef in berichtnieuws
Xns9E83D54714BFDwunderpsdrscray@216.151.153.189...
> "R.Wieser" <(E-Mail Removed)> wrote in
> news:4d4bd16e$0$34849$(E-Mail Removed):
>
> > Hello All,
> >
> > I've got a problem with XP's command-prompts (cmd.exe)
> > commandline-history behaviour:
> >
> > Quite often when I press the "up" arrow (to go back to the
> > previously typed commandline, or, on a next key press, to the one
> > above it) I find myself ... somewhere in that list, but definitily
> > *not* at the bottom of it.
> >
> > This is disconcerting, as it can land me on a command which
> > nullifies all the work I've previously done on a file (by *again*
> > copying an origional file to my working-folder, thereby erasing
> > the work I just did on the copy).

>
> The up-arrow will take you to the last command that you executed. If
> the last command that you executed was generated by hitting the up-
> arrow to go to a previous command and then you modify that command,
> then the last command executed would be the last command in the
> history list. OTOH, if you go to a command in history with the up-
> arrow and execute it unaltered, then the last command you executed
> was that line in history and subsequent up-down arrows will be
> relative to that point.
>
>
> > My question therefore is: can I tell the commandline-history to
> > *allways* go to the bottom of its history-list (and not display
> > any form of a to me counter-productive 'intelligence') ?

>
> Sure, just press Page-Down before pressing the up-arrow.
>
> > If that is not possible, how do I disable that commandline-history
> > (without blocking other programs to take its place -- Can't seem
> > to get an old version (W98se) of DosKey.com running ...).

>
> You can change the length of the history buffer to "1".
> For example:
>
> C:\>doskey /reinstall /listsize=1
>
> Keep in mind that after Windows 98 & ME, the command line window is
> not really a DOS window but a program emulating it.
>
> Some good reading that you might be interested in:
>
> "The Windows NT Command Shell"
> < http://technet.microsoft.com/en-us/l.../cc723564.aspx >
>
> HTH,
> John



 
Reply With Quote
 
glee
Guest
Posts: n/a
 
      6th Feb 2011
"R.Wieser" <(E-Mail Removed)> wrote in message
news:4d4edf2f$0$81485$(E-Mail Removed)...
> Hello Glee,
>
>> > snip
>> > Can't seem to get an old
>> > version (W98se) of DosKey.com running ...

>>
>> Windows XP does not use Doskey.com from Win98, it uses Doskey.exe, in
>> the system32 folder.
>>
>> You should not need to use Doskey, since the behavior you want is
>> built
>> into the command prompt in XP.

>
> My apologies if I was not clear, but the reason I posted is that that
> program does *NOT* exhibit the behaviour I expect from it.
>
> As it does not I would like either to know of a way to make it behave
> consistently, or to be able to replace it. If its really a part of
> the
> cmd.exe either of the above might be difficult to do.


Have you tried running Doskey.exe (not Doskey.com) to see if it has the
behavior you want, or if it gives you the same problem as cmd.exe?

--
Glen Ventura
MS MVP Oct. 2002 - Sept. 2009
CompTIA A+
http://dts-l.net/

 
Reply With Quote
 
R.Wieser
Guest
Posts: n/a
 
      6th Feb 2011
Hello Glee,

> Have you tried running Doskey.exe (not Doskey.com) to see if it
> has the behavior you want, or if it gives you the same problem as
> cmd.exe?


I've even tried to remove that DosKey.exe program (from the system32 as well
as the dllcache folders and rebooting afterwards), but to no avail. The
DosKey.exe program itself knows a /reinstall switch, but no /uninstall (or
equivalent) one. And it looks like that before I can get rid of that one I
can't even start to test others.

By the way: Looking at the commands that it uses (like
SetConsoleCommandHistoryMode) and googeling them does not really turn up
anything usable either. Bummer.

Oh yeah: The first thing I tried (before posting here) was to google "DosKey
xp". Not much there either ...

Regards,
Rudy Wieser


-- Origional message:
glee <(E-Mail Removed)> schreef in berichtnieuws
iimtm3$3nd$(E-Mail Removed)...
> "R.Wieser" <(E-Mail Removed)> wrote in message
> news:4d4edf2f$0$81485$(E-Mail Removed)...
> > Hello Glee,
> >
> >> > snip
> >> > Can't seem to get an old
> >> > version (W98se) of DosKey.com running ...
> >>
> >> Windows XP does not use Doskey.com from Win98, it uses Doskey.exe, in
> >> the system32 folder.
> >>
> >> You should not need to use Doskey, since the behavior you want is
> >> built
> >> into the command prompt in XP.

> >
> > My apologies if I was not clear, but the reason I posted is that that
> > program does *NOT* exhibit the behaviour I expect from it.
> >
> > As it does not I would like either to know of a way to make it behave
> > consistently, or to be able to replace it. If its really a part of
> > the
> > cmd.exe either of the above might be difficult to do.

>
> Have you tried running Doskey.exe (not Doskey.com) to see if it has the
> behavior you want, or if it gives you the same problem as cmd.exe?
>
> --
> Glen Ventura
> MS MVP Oct. 2002 - Sept. 2009
> CompTIA A+
> http://dts-l.net/
>



 
Reply With Quote
 
R.Wieser
Guest
Posts: n/a
 
      17th Feb 2011
Hey people,

Looking at the kind & type of replies I got it looks like I asked my
question in the wrong newsgroup.

Does anyone know where I should ask my question instead ?

Regards,
Rudy Wieser


-- Origional message:
R.Wieser <(E-Mail Removed)> schreef in berichtnieuws
4d4f1a8b$0$81481$(E-Mail Removed)...
> Hello Glee,
>
> > Have you tried running Doskey.exe (not Doskey.com) to see if it
> > has the behavior you want, or if it gives you the same problem as
> > cmd.exe?

>
> I've even tried to remove that DosKey.exe program (from the system32 as

well
> as the dllcache folders and rebooting afterwards), but to no avail. The
> DosKey.exe program itself knows a /reinstall switch, but no /uninstall (or
> equivalent) one. And it looks like that before I can get rid of that one I
> can't even start to test others.
>
> By the way: Looking at the commands that it uses (like
> SetConsoleCommandHistoryMode) and googeling them does not really turn up
> anything usable either. Bummer.
>
> Oh yeah: The first thing I tried (before posting here) was to google

"DosKey
> xp". Not much there either ...
>
> Regards,
> Rudy Wieser
>
>
> -- Origional message:
> glee <(E-Mail Removed)> schreef in berichtnieuws
> iimtm3$3nd$(E-Mail Removed)...
> > "R.Wieser" <(E-Mail Removed)> wrote in message
> > news:4d4edf2f$0$81485$(E-Mail Removed)...
> > > Hello Glee,
> > >
> > >> > snip
> > >> > Can't seem to get an old
> > >> > version (W98se) of DosKey.com running ...
> > >>
> > >> Windows XP does not use Doskey.com from Win98, it uses Doskey.exe, in
> > >> the system32 folder.
> > >>
> > >> You should not need to use Doskey, since the behavior you want is
> > >> built
> > >> into the command prompt in XP.
> > >
> > > My apologies if I was not clear, but the reason I posted is that that
> > > program does *NOT* exhibit the behaviour I expect from it.
> > >
> > > As it does not I would like either to know of a way to make it behave
> > > consistently, or to be able to replace it. If its really a part of
> > > the
> > > cmd.exe either of the above might be difficult to do.

> >
> > Have you tried running Doskey.exe (not Doskey.com) to see if it has the
> > behavior you want, or if it gives you the same problem as cmd.exe?
> >
> > --
> > Glen Ventura
> > MS MVP Oct. 2002 - Sept. 2009
> > CompTIA A+
> > http://dts-l.net/
> >

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IE7 clear browser history at commandline - 161007 Vighneswar Windows Vista General Discussion 2 16th Oct 2007 04:49 PM
IE7 clear browser history at commandline - 161007 Vighneswar Windows Vista Security 2 16th Oct 2007 04:49 PM
More on Randomness Ethan Strauss Microsoft C# .NET 2 17th Jan 2007 05:27 PM
Re: Not true randomness... Matthias Steinbart Microsoft C# .NET 0 10th Aug 2004 09:27 PM
commandline for delete history or cookies? Jeff Malka Windows XP General 1 23rd Sep 2003 05:52 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:06 PM.