Hello!
I am fairly new to automating CATIA via VBA.
I am able to create a new ParameterSet but i am unable to rename it using VBA.
For eg. the following code creates a Parameter Set with its name as per index of that ParameterSet:
Sub CATMain()
Set oDoc = CATIA.ActiveDocument
Set oPart = oDoc.Part
Set oParams = oPart.Parameters
Set oRootParams = oParams.RootParameterSet
oParams.CreateSetOfParameters (oRootParams)
Set myParamset = oRootParams.ParameterSets.Item(oRootParams.ParameterSets.Count)
Set myParams = myParamset.DirectParameters
Set myReal = myParams.CreateReal("Height1", 10)
Set myReal = myParams.CreateReal("Height2", 100)
oPart.Update
End Sub
Can someone please explain how do we rename a ParameterSet in VBA.
Thanks in advance!
I am fairly new to automating CATIA via VBA.
I am able to create a new ParameterSet but i am unable to rename it using VBA.
For eg. the following code creates a Parameter Set with its name as per index of that ParameterSet:
Sub CATMain()
Set oDoc = CATIA.ActiveDocument
Set oPart = oDoc.Part
Set oParams = oPart.Parameters
Set oRootParams = oParams.RootParameterSet
oParams.CreateSetOfParameters (oRootParams)
Set myParamset = oRootParams.ParameterSets.Item(oRootParams.ParameterSets.Count)
Set myParams = myParamset.DirectParameters
Set myReal = myParams.CreateReal("Height1", 10)
Set myReal = myParams.CreateReal("Height2", 100)
oPart.Update
End Sub
Can someone please explain how do we rename a ParameterSet in VBA.
Thanks in advance!