# UP arrow won't load last used command



## bonehead79 (Jan 10, 2008)

Greetings!

I've experienced this on a number of PC's: When using the command prompt, all of a sudden, I can't get my previous commands to come up by hitting the UP arrow (or F3, or any other key). Can anyone tell me how to fix this issue?

Thanks, J


----------



## ZeRealBigBoss (Mar 17, 2007)

Assuming you are running DOS V6.22 or V7: call doskey.com; that will load the keyboard command buffer. doskey /? for help.


----------



## bonehead79 (Jan 10, 2008)

Thanks, ZRBB.

BTW, I'm currently addressing this problem on an XP SP2 box, but I've experienced it with ME, and '98 SE as well.

I played with some of the DOSKEY commands and hot keys. </HISTORY> didn't show anything. </REINSTALL> didn't change anything (that I could see) with regard to the arrow keys. I checked some of the other listed hot keys, too:

F7 just echos a <^@>
F6, a <^Z>
F5. a <@>
ESC, a <\>

These outputs were present before and after the reinstall(s).

Please let me know if anything I've reported helps to identify my problem (excluding my obvious limited knowledge and experience with the Windows CLI).

Thanks again,

Bonehead


----------



## ZeRealBigBoss (Mar 17, 2007)

sometimes is required; I have not always the time to post here.

On both my W98SE and the XP2 the DOSKEY works, on the latter with cmd.exe in the DOS box as well as with command.com in it. I tried to recreate your error to see where it might come from, but, try as I might, I could not get any of the two malfunctioning. Strange: if you want it to go wrong, it doesn't, if you don't, it does.

I must admit that I can not guess, educated or wild, what might cause it. Sorry for that. Maybe Bob Cerelli, blues_harp or flavallee know.


----------



## TheOutcaste (Aug 8, 2007)

For XP, are you perhaps running *command.com* instead of *cmd.exe*? The version of command.com that comes with XP is very limited. It does not have a command history buffer (despite the fact that is shows on the Properties dialog) and doskey loads but does not function. Doskey can create macros but they won't execute.

With cmd.exe you don't need doskey for the command history to work, but is useful if you want to create macros.

I haven't a clue as to why ME or 98 wouldn't function, unless someone copied the XP version of command.com to those systems.

HTH

Jerry


----------



## ChuckE (Aug 30, 2004)

How are you getting to your DOS window? I suspect it is like *TheOutcaste* said, that you are using *command.com* and not *cmd.com*.

Using your WinXP, try this and tell use what happens or changes:
Use the *Start>Run* window, and type in *cmd*.
Then click the [OK] button, and try your tests in that DOS window.

You should not need to use Doskey, to get the previously used commands to appear with the {Up Arrow}.


----------

