Jump to content
mansin

The problem of tcl command "*calculateElemDrapingAngles"

Recommended Posts

Hi, everyone.

    I encountered a problem when I record tcl command of "Drape Estimator" in the GUI. In command.tcl file, it gives the the command:

*calculateElemDrapingAngles 1 "./draping1001/draping1001.res" "DrapeTable_PLY1001" 1 2 1001

    While in the help files, the explanation of the command of "*calculateElemDrapingAngles" is

*calculateElemDrapingAngles mark_id result_file table_name fiber_vector stamping_vector ply_id

result_file: Reserved for future use.  Must be set to "".

 (1) How is the result file "./draping1001/draping1001.res"  generated? (the generation process of the result file was not recorded in the "command.tcl" file )  What's the full directory path of the result file? (in HyperWorks 14.0)

 (2) The parameter of result_file in the command cannot be blank when executing this command. The software throws a error: A results file must be specified in the files panel. So, is there a problem with the explanation of the help files to this command?

 

Can anybody gives me some advices?

Thanks.

Share this post


Link to post
Share on other sites

Hi,

Try loading a result file into hypermesh first (menu File>Load>Results)

maybe the command will take a loaded result file as it argument, and temporary not permit user to indicate it arbitrary.

Share this post


Link to post
Share on other sites

Hi, tinh.

I found the result file (.../draping****.res) was generated automatically in the work directory when executing "Drape Estimator" function. But this result file was deleted automatically when the "Drape Estimator" function was finished. I cannot run the recorded command.tcl file properly because the generated process of the result file (or directory) was not recorded in "command.tcl" file and the drape results no longer existed. I guess the "Drape Estimator" operation called an "unkown" command to calculate the drape parameters before the command "*calculateElemDrapingAngles" executed, but I don't know which "unknown" command is called. I would appreciate it if you could help me solve this problem.

I attached the tested .hm file (drape_test.hm) and recorded command.tcl file (command-1.tcl) (only contained "Drape Estimator" operation by right click on ply) and the catured picture about temporary drape results.  

1.PNG

Share this post


Link to post
Share on other sites

Hi

I invoke "Drape Estimator", it pops up a window named "Drape Estimator"

I click "Apply", it runs, then a table is generated.

But I don't see any command output to command.tcl file

and I don't see any *.res file in working dir while it running, either.

 

if your hm version is low, please update to v2017.2

 

If you want to run drape estimator by script in v2017.2, the code is like this:

 

set ::ply_ids $PlyID

source [file join $hm_scripts_dir br views composite operations drapeestimator_perform.tcl]

wm withdraw .drapeestimatorgui

::hm::plydraping::OnApply

destroy .drapeestimatorgui

 

 

 

 

Share this post


Link to post
Share on other sites

Hi, @tinh.

     I found the code you advised cannot be run in HyperStudy. It seems that the code cannot be recogonized by HyperStudy properly. How to solve this new problem?

    Thanks.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
You are posting as a guest. If you have an account, please sign in.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...