All Frameworks Object Hierarchy This Framework Indexes
Dim CATDocs As Documents Set CATDocs = CATIA.Documents Dim partdoc As Document Set partdoc = CATDocs.Add("CATPart") Dim part as Part Set part = partdoc.Part Dim relations as Relations Set relations = part.Relations Dim RuleBase as ExpertRuleBaseRuntime Set RuleBase = relations.Item("RB1") Dim RuleSet as ExpertRuleSet Set RuleSet = RuleBase.RuleSet
o Func CreateCheck( | iName, | |
iCheckVariables, | ||
iCheckBody, | ||
iRuleSet) As |
Dim CATDocs As Documents Set CATDocs = CATIA.Documents Dim partdoc As Document Dim part as Part Dim CheckSolid as ExpertCheck Dim ruleset as ExpertRuleSet Dim CheckHole as ExpertCheck Set partdoc = CATDocs.Add("CATPart") Set part = partdoc.Part Set CheckSolid = part.Relations.Item("RuleBase").RuleSet.CreateCheck ("SolidActivity", "Sol : Solid", "Sol.Activity == True", "RuleSet.1") Set ruleset = part.Relations.Item("RuleBase").RuleSet.CreateRuleSet ("RuleSet.2", "") Set CheckHole = ruleset.CreateCheck ("HoleActivity", "H : Hole", "H.Activity == True", "")
o Func CreateRuleSet( | iName, | |
iRuleSet) As |
Dim CATDocs As Documents Set CATDocs = CATIA.Documents Dim partdoc As Document Set partdoc = CATDocs.Add("CATPart") Dim part as Part Set part = partdoc.Part Dim RS1 as ExpertRuleSet RS1 = part.Relations.Item("RuleBase").RuleSet.CreateRuleSet ("RuleSet.1", "") Dim RS2 as ExpertRuleSet RS2 = part.Relations.Item("RuleBase").RuleSet.CreateRuleSet ("RuleSet.2", "RuleSet.1")
o Func CreateRule( | iName, | |
iRuleVariables, | ||
iRuleBody, | ||
iRuleSet) As |
Dim CATDocs As Documents Set CATDocs = CATIA.Documents Dim partdoc As Document Set partdoc = CATDocs.Add("CATPart") Dim part as Part Set part = partdoc.Part Dim rulesolid as ExpertRule Set rulesolid = part.Relations.Item("RuleBase").RuleSet.CreateRule ("DesactivateIfActivatedOnSolid", "Sol : Solid", "Sol.Activity == True then Sol.Activity = False", "RuleSet.1") Dim ruleset as ExpertRuleSet Set ruleset = part.Relations.Item("RuleBase").RuleSet.CreateRuleSet ("RuleSet.2", "") Dim rulehole as ExpertRule Set rulehole = ruleset.CreateRule ("DesactivateIfActivatedOnHole", "H : Hole", "H.Activity == True then H.Activity = False", "")
Copyright © 2003, Dassault Systèmes. All rights reserved.