DOS: Open Text File and have the Cursor @ the End of File

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
FirstBorn
Posts: 2
Joined: 02 Aug 2011 19:03

DOS: Open Text File and have the Cursor @ the End of File

#1 Post by FirstBorn » 02 Aug 2011 19:07

Hi,

Thank you for your help.

Had to build a PC to use 'cuz My Old PC when "Ka-put!"

So, Have to use Vista instead of XP.

Vista does NOT allow (Well, THIS PC, at least) to use .LOG
at the beginning of a Text file to Time and Date Stamp
the file upon opening...

SO, I wrote a Batch File to do this FOR Me,
but, can't get the file to open w/ the Time and Date stamp,
having the Cursor at the End of the File.

I've attached the code here for the Example of what I'm doing.

Any Ideas on what I'm doing wrong or what I'm missing?

Thank You VERY MUCH for Your Help in Advance!

Thanks!

Code: Select all

ECHO %DATE% %TIME% >> FileName.txt

START filename.txt &GOTO:EOF
REM &GOTO:EOF and GOTO:EOF or GOTO EOF does not work

trebor68
Posts: 146
Joined: 01 Jul 2011 08:47

Re: DOS: Open Text File and have the Cursor @ the End of Fil

#2 Post by trebor68 » 03 Aug 2011 01:21

The code that you write will have two command in one row.
command 1: start filename.txt
command 2: goto :eof

Command 1 will open the file filename.txt with the text editor (standard: notepad).
Command 2 will go to the end of the batch (bat-file or cmd-file).

The program notepad have not a option, that will set the cursor to the end of the file.

With the program EditPad is this in the "Pro" version possible. Not possible in the "Light" version.

If you use the program EditPad for TXT files, you can use the following command:

Code: Select all

EditPad /l-1 filename.txt

FirstBorn
Posts: 2
Joined: 02 Aug 2011 19:03

Re: DOS: Open Text File and have the Cursor @ the End of Fil

#3 Post by FirstBorn » 03 Aug 2011 01:30

Thank you trebor68 Very Much for your help!

I REALLY Appreciate it!

Post Reply