Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Determinde the model parameter name

3 REPLIES 3
Reply
Message 1 of 4
Anonymous
370 Views, 3 Replies

Determinde the model parameter name

I used this code to make a new workplane which is offset from the XZ plane
by a distance of .2
How to determine what model parameter (name) of .2?
Thx,

On Error Resume Next
Dim oDoc As PartDocument
Set oDoc = ThisApplication.ActiveDocument

Dim oOriginWP As WorkPlane
Set oOriginWP = oDoc.ComponentDefinition.WorkPlanes.Item("YZ Plane")

Dim oNewWP As WorkPlane
Set oNewWP = oDoc.ComponentDefinition.WorkPlanes.Item("New WorkPlane")
If Err Then
Err.Clear
Else
Set oNewWP =
oDoc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(oOriginWP, 0.2,
False)
oNewWP.Name = "New WorkPlane"
End If

--
www.CVAengineering.com

IV11 Pro. sp2 and IV2008 Pro. sp1
Vault 2008 sp1
Window XP Pro sp2
Pentium 3.2 Ghz, 3.0 GB of RAM
NVIDIA FX 3400 91.85
SpacePilot V 3.3.6
3 REPLIES 3
Message 2 of 4
Anonymous
in reply to: Anonymous


oNewWP.Definition.Offset.Name


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
I
used this code to make a new workplane which is offset from the XZ plane

by a distance of .2
How to determine what model parameter (name)
of  .2?
Thx,

On Error Resume Next
    Dim
oDoc As PartDocument
    Set oDoc =
ThisApplication.ActiveDocument

    Dim oOriginWP As
WorkPlane
    Set oOriginWP =
oDoc.ComponentDefinition.WorkPlanes.Item("YZ Plane")

   
Dim oNewWP As WorkPlane
    Set oNewWP =
oDoc.ComponentDefinition.WorkPlanes.Item("New
WorkPlane")
    If Err
Then
       
Err.Clear
           
Else
        Set oNewWP =

oDoc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(oOriginWP, 0.2,

False)
        oNewWP.Name = "New
WorkPlane"
    End If

--

href="http://www.CVAengineering.com">www.CVAengineering.com


IV11
Pro. sp2 and IV2008 Pro. sp1
Vault 2008 sp1
Window  XP Pro 
sp2
Pentium 3.2 Ghz, 3.0 GB of RAM
NVIDIA FX 3400  
91.85
SpacePilot  V 3.3.6
Message 3 of 4
Anonymous
in reply to: Anonymous


Thx, Brian

CVA


 

IV11 Pro. sp2 and IV2008 Pro. sp1
Vault 2008 sp1
Window  XP
Pro  sp2
Pentium 3.2 Ghz, 3.0 GB of RAM
NVIDIA FX 3400  
91.85
SpacePilot  V 3.3.6


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


oNewWP.Definition.Offset.Name


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
I
used this code to make a new workplane which is offset from the XZ plane

by a distance of .2
How to determine what model parameter (name)
of  .2?
Thx,

On Error Resume Next
    Dim
oDoc As PartDocument
    Set oDoc =
ThisApplication.ActiveDocument

    Dim oOriginWP As
WorkPlane
    Set oOriginWP =
oDoc.ComponentDefinition.WorkPlanes.Item("YZ
Plane")

    Dim oNewWP As
WorkPlane
    Set oNewWP =
oDoc.ComponentDefinition.WorkPlanes.Item("New
WorkPlane")
    If Err
Then
       
Err.Clear
           
Else
        Set oNewWP =

oDoc.ComponentDefinition.WorkPlanes.AddByPlaneAndOffset(oOriginWP, 0.2,

False)
        oNewWP.Name = "New
WorkPlane"
    End If

--

href="http://www.CVAengineering.com">www.CVAengineering.com


IV11
Pro. sp2 and IV2008 Pro. sp1
Vault 2008 sp1
Window  XP Pro 
sp2
Pentium 3.2 Ghz, 3.0 GB of RAM
NVIDIA FX 3400  
91.85
SpacePilot  V 3.3.6
Message 4 of 4
tneff2
in reply to: Anonymous

Hi Brian,

 

Do you know how I would be able to find function calls like the one you used here? If this post wasn't here there would be no way to figure out that there are more properties under the .Definition object. Is there a better way to use the object browser in VS?

 

Thanks,

-Thomas

 

 

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report