Hi Guys,
I'm trying to automate the creation of CBEAM elements along a node path wrt to a given 'template' element which is already in the model. What I could achive so far is the creation of the CBEAM elements with help of the *feature_add command to create plot elements along a given nodepath and then switch the configuration of the created PLOTEL. These PLOTEL can now be 'switched' to CBEAMs utilizing the *attributeupdateint, *attributeupdatedouble and *attributeupdateentity command. The correct property assignment can be done with the *propertyupdate command.
So far so good. In the next step, the orientation and offset vectors of the newly created CBEAM elements have to be adjusted with the *barelementupdatewithoffsets command. But the questions is, how can I extract these vectors from the 'template' element. I already tried to use the hm_attributevalue / hm_atttributearrayvalue and hm_getentityvalue, but I don't know the correct keyword, to access the needed information. This leads me to two questions:
- Does anybody know the correct command / keyword to obtain the orientation and offset vector data from a CBEAM element or
- is there any possibility / a list to get all the possible query options to make on an element.
Thanks for you help,
Sven
CODE:
# get nodes along beam path
*createlistbypathpanel nodes 1 'Select nodes for the beam:'
# save nodes in list
set lstNodeList [hm_getlist nodes 1]
# create plot element along node path
*features_add 1 0 0
# put newly created element in element mark 1
*createmark elms 1 'by comp name' '^open features'
# save plot element in list
set lstPlotElementList [hm_getmark elms 1]
# switch configuration to bar for all elements in list
*configedit 1 'bar2'
foreach numPlotElementID $lstPlotElementList {
*attributeupdateint elms $numPlotElementID 4841 1 2 0 0
*attributeupdatedouble elms $numPlotElementID 3273 1 0 0 0
*attributeupdateentity elms $numPlotElementID 3271 1 0 0 nodes 0
*attributeupdateentity elms $numPlotElementID 3272 1 0 0 nodes 0
}
# choose template element
*createmarkpanel elms 2 'Select template CBEAM element'
# save element id in list
set numTemplateElementID [hm_getmark elms 2]
# get property from template element
set numHMPropertyID [hm_getentityvalue elms $numTemplateElementID property 0]
# get property name
set strHMPropertyName [hm_getentityvalue props $numHMPropertyID name 1 -byid]
# put new beam elements to mark
*createmark components 1 '^open features'
# assign properties on component
*propertyupdate components 1 '$strHMPropertyName'
now the part with getting the element properties (X1 X2 X3 W1A W2A W3A W1B W2B W3B) from the 'template' element should come