Re: copy and move files



Fluid wrote:

Hi, i need help.i am a quite new user of fortran. I would like to
rename a file (used as input file) and move it to another directory.
Which command can I use?
thanks

If you are using a compiler which supports POSIX libraries, such as
the Intel compiler, it is trivial. First call PXFLINK to create a new
link to the data, then PXFUNLINK to remove the old link to the data:

character(100) :: oldfn, newfn
:
call PXFLINK (oldfn, len_trim (oldfn), newfn, len_trim (newfn), ierr)
if (ierr /= 0) some error occurred...

call PXFUNLINK (oldfn, len_trim (oldfn), ierr)
if (ierr /= 0) some error occurred...
:

W.
.