×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Reading directory path for input file

Reading directory path for input file

Reading directory path for input file

(OP)
Hi All,

Is it possible to read the directory path of the input file which has been read and then store it in a variable.

This way I can use that variable, concatenate it with another string (file name) which will server as the path for my output file.

This will help me move the code from one machine to another without going through the hassle of changing all the paths for output file.

Regards

RE: Reading directory path for input file

Hi,
you surely can define a "string" variable.
But, I seem to remember that there is no key of the *GET command to allow the retrieval of the current working directory.
If your APDL is used to read/write files in the jobname's directory, however, you don't need to bother about the directory itself since the file reading/writing will be by default executed there.
... Or I may have misunderstood your problem...

Regards

RE: Reading directory path for input file

(OP)
Hi cbrn

You got my problem right. The problem with using strings is that they are limited in length and thus i am not able to putt the full path after concatenation.

Thus I was looking for something more direct.

Regards

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources