×
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

API Programming (post processing).

API Programming (post processing).

API Programming (post processing).

(OP)
Hi guys,

I hope someone here can help me out with API programming. I looked through the femap forum here and all the API threads are very old and outdated so thats why i am opening a new thread. I made a macro that's suppose to change some nodes and element (loop) and rerun the analysis multiple times depending on the number of changes. The problem is that if there are more than 50 analysis FEMAP/my computer crashes. What I was looking for was some function to make sure the analysis are after the previous one has been completed. I'm currently reading into "FeEvent" but since I'm new to the whole programming gig, its all blur at the moment. Any help will be much appreciated. Thank you in advance

Marvin Gopal

RE: API Programming (post processing).

Hi Marvin,
My first thought was that I'm surprised you made it to 50 analyses before your computer crashed! I assume that when you run the analysis it is running in FEMAP, and when it finishes it imports the results? It depends on the size of your model, but that could be just too much data for one file. I would save each iteration as a different model and just export the analysis files (.dat or .nas or whatever) to run in a batch outside of FEMAP. Then you can import each result file into the corresponding .modfem file.
However, your specific question was about waiting for the run to finish. I have never used FeEvent, or ran an analysis from an API, but I have imported results and waited for that to complete before moving on. It looked like this:
'import Output file
App.feFileReadNastranResults(8,op2Title)
Do While App.feFileProgramRunning()= FE_OK
Wait(2)
Loop

This is in chapter 3.18 File Utility Methods of the api.pdf. feFileExecute might also work, since you can ask it to wait until the program has finished running.

Hope this helps!

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