Operating System - OpenVMS
Showing results for 
Search instead for 
Did you mean: 

Deleting files created in VI?


Deleting files created in VI?

Hello -

I have several files that were created in VI like for example> john01.txt and I would like to remove them or delete them.

How can I do this in OpenVMS?
Hein van den Heuvel
Honored Contributor

Re: Deleting files created in VI?

At the DCL prompt, just type in "DELETE john01.txt"

It will complain... about requireing a version number.
So give it one (or more).

Just delete the most recent version:

$ DELETE john01.txt;

Delete any and all versions:

$ DELETE john01.txt;*

You might want to add /CONFIRM while learning.

And you might want to try with $ DIRECTORY first to see what you are aming at, then replace the DIRECTORY with DELETE and re-execute.

Be sure to carefull read


And please consider checking the VMS User documentation

Good luck,

Anton van Ruitenbeek
Trusted Contributor

Re: Deleting files created in VI?

Created in VI as in vi ? Un-x vi ?
If so, ugly but it works.
Just delete them bij delete 'filename'.
If there are any unknown characters in the file.
Just delete them bij:
$ a = f$search("john01.txt")
$ show symbol a ! just make sure
$ delete/nolog/noconfirm "''a'"
> these dubble quotes etc. for the unreadable/printable characters.

NL: Meten is weten, maar je moet weten hoe te meten! - UK: Measuremets is knowledge, but you need to know how to measure !