Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

How to count the parameters below GeoSet

Status
Not open for further replies.

Sidtha

Aerospace
Nov 25, 2012
30
IN
Hi,

I need to count the parameters below the GeoSet using vba
In geoset we have multiple UDF's from UDF's need to count how many parameters are there inside each UDF.
For the reference please see below pictures.
count1_babt8e.jpg

count_pdm9dt.jpg
 
Replies continue below

Recommended for you

Use:
dim oParamsInFeature : set oParamsInFeature = oPart.Parameters.Sublist(myObject, false)

regards,
LWolf
 

Hi LWolf,

Thank your for help, below is my code to extract all the parameters, but i am unable to get extactly how many parameters in each UDF.
pelase help me to get it

Dim oCurrentTreeNodePart
Dim MBod
Set oCurrentTreeNodePart = oCurrentTreeNode.ReferenceProduct.Parent.Part
'Debug.Print oCurrentTreeNodePart.Name
Set mBody = oCurrentTreeNodePart.MainBody
'Debug.Print mBody.Name
Set objParameters = oCurrentTreeNodePart.Parameters
' Loop on parameters to retrieve them
For j = 1 To objParameters.Count
Set objParameter = objParameters.Item(j)
strParmName = objParameter.Name
'Debug.Print strParmName
Application.StatusBar = strParmName

strParmValue = objParameter.ValueAsString
'Debug.Print strParmValue
'Debug.Print strParmName & " = " & strParmValue

Next

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top