Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations JAE on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing properties standard shape reference point location by API function .pval(51) in v10.3.1

Status
Not open for further replies.

faremusai

Mechanical
Joined
Feb 23, 2016
Messages
23
Location
HK
The default location of reference point for a standard shape in FEMAP is "1". I want to change it to other location by using the API function .pval(51) e.g. to point 7. I have tried using the command pr.pval(51) = 7 then, .ComputeStdShape, then pr.Put(ID) to update the properties. There is no error nor warning messages after running the script. But the reference point was not updated, still at location "1".

If the reference point was changed manually throught tge "Properties" dialogue box and then read the new value by using the function Msgbox "xxx: " & pr.pval(51), the new reference point location "7' was displayed.

If the command .ComputeStdShape was removed or .pval(51) was moved to a location after the .ComputeStdShape command, the reference point location was updated as expected.

Is it true that the command .pval(51) CANNOT be used before the command .ComputeStdShape?

 
faremusai,

For future inquiries, please use the regularly monitored FEMAP forum found here:

You are close - the issue is that you need to use "pr.Put( pr.ID )" BEFORE "pr.ComputeStdShape(...)". Otherwise, you have not updated the property with your new reference point and you will always be computing on the original, unchanged, property.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top