Discussion Groups

Robot Structural Analysis

Reply
Contributor
ethor
Posts: 19
Registered: ‎10-13-2011

IRobotNodeCompatibilityDef API Example please

136 Views, 3 Replies
12-05-2011 10:32 AM

I am trying to create compatibility properties for nodes using the API. I am not sure of how to use IRobotNodeCompatibilityDef. I am able to add the label and define its data but how do you use the  IRobotNodeCompatibilityDef methods to define master and compatibility nodes? Can you please provide a short example?

Please use plain text.
Product Support
Rafal.Gaweda
Posts: 5,587
Registered: ‎04-26-2010

Re: IRobotNodeCompatibilityDef API Example please

12-06-2011 02:01 AM in reply to: ethor

by CompatibilityDef you can only get \ check compatibility created on model 

 

 

Dim VLabel As RobotLabel
Dim VData As RobotNodeCompatibilityData
Dim Vdef As RobotNodeCompatibilityDef

 

'defining and assigning compatibility

 

Set VLabel = Robapp.Project.Structure.Labels.Create(I_LT_NODE_COMPATIBILITY, "comp")
Set VData = VLabel.Data
VData.UZ = True
Robapp.Project.Structure.Labels.Store VLabel

master_node_number=123

dim Bars as String

Bars = "3 4 5" 'bars list to which "slave" node will ve assigned 

Robapp.Project.Structure.Nodes.CompatibleNodes.Set master_node_number, Bars, "comp"

 

' checking compatibility defined on structure
Set Vdef = Robapp.Project.Structure.Nodes.CompatibleNodes.Get(1)
aaa = Vdef.LabelName  'checking compatibility name \ label used in this compatibility

bbb = Vdef.Bars 'bars list 
ccc = Vdef.Main  'checking compatibility main node number
ddd = Vdef.Compatible ' checking compatible node number

 



Rafal Gaweda
Please use plain text.
Contributor
ethor
Posts: 19
Registered: ‎10-13-2011

Re: IRobotNodeCompatibilityDef API Example please

12-06-2011 07:29 AM in reply to: Rafal.Gaweda

Why is it nessicary to have a bars list. What if the nodes i want to "couple" are connected to shell/area elements? Or no elements at all?

Please use plain text.
Product Support
Rafal.Gaweda
Posts: 5,587
Registered: ‎04-26-2010

Re: IRobotNodeCompatibilityDef API Example please

12-06-2011 07:47 AM in reply to: ethor

ethor wrote:

Why is it nessicary to have a bars list. What if the nodes i want to "couple" are connected to shell/area elements? Or no elements at all?

 

Even in Robot itself it is not intended to create compatibility between FEs. If you know the trick you can do it.

You can define compatibility between FEs node and bar it the way that main node will belong to FEs and slave node to selected bar(s)

 

compes.jpg


 



Rafal Gaweda
Please use plain text.