• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    Autodesk Robot Structural Analysis

    Reply
    Contributor
    samuel.pereira
    Posts: 22
    Registered: ‎01-02-2012

    Robot Steel API - Member definition parameters

    205 Views, 7 Replies
    06-19-2012 04:30 AM

    Hello,

     

    I'm trying to define members parameters, using Robot Steel API, to design a bar structure steel with EN1993-1.

    I have seen the document "Robot API Steel Design" but I can’t do it. It’s possible provide a complete example to "Visual Basic -Microsoft Excel" for a “Bar” type?

     

    Thanks

    Please use plain text.
    Product Support
    Posts: 2,731
    Registered: ‎04-26-2010

    Re: Robot Steel API - Member definition parameters

    06-19-2012 05:26 AM in reply to: samuel.pereira

    Look closer at paragraphs 4.4.1 and 4.4.2 in mentioned doc.

     

    Examlpe below

    Set all \ required RDimMembParams in place where you cae see commented dots in code below

     

     

    Dim RobApp As RobotApplication
    Set RobApp = New RobotApplication
    
        RobApp.Project.Preferences.SetActiveCode I_CT_STEEL_STRUCTURES, "ENV 1993-1:1992"
    
        Dim RLabel As IRobotLabel
        Dim RdimLabelData  As IRDimMembDefData
        Dim RDimMembParams As IRDimMembParamsEC3
        
            Set RLabel = RobApp.Project.Structure.Labels.Create(I_LT_MEMBER_TYPE, "My Label")
            Set RdimLabelData = RLabel.Data
            
            RdimLabelData.SetDeflYZRelLimit I_DMDDDT_DEFL_Y, 100
            RdimLabelData.SetDeflYZRelLimit I_DMDDDT_DEFL_Z, 200
            RdimLabelData.SetDisplXYRelLimit I_DMDDDT_DISP_X, 300
            RdimLabelData.SetDisplXYRelLimit I_DMDDDT_DISP_Y, 400
            
    
            Set RDimMembParams = RdimLabelData.CodeParams
            
            RDimMembParams.BuckLengthCoeffY = 10
            '......
            RdimLabelData.CodeParams = RDimMembParams
            RobApp.Project.Structure.Labels.Store RLabel

     

     




    Rafal Gaweda
    Product Support
    Autodesk, Inc.
    Please use plain text.
    Contributor
    samuel.pereira
    Posts: 22
    Registered: ‎01-02-2012

    Re: Robot Steel API - Member definition parameters

    06-19-2012 06:17 AM in reply to: samuel.pereira

    Thank you!

    Please use plain text.
    Contributor
    samuel.pereira
    Posts: 22
    Registered: ‎01-02-2012

    Re: Robot Steel API - Member definition parameters

    06-19-2012 06:50 AM in reply to: RG_Adsk

    Hello,

     

    When I run the Macro in Excel, it return an error:

    Run-time '13'

    Type mismatch

     

    It occurs on line:

    Dim RdimLabelData  As IRDimMembDefData

     

    Annex image with the error.

     

    Thank you!

    Please use plain text.
    Product Support
    Posts: 2,731
    Registered: ‎04-26-2010

    Re: Robot Steel API - Member definition parameters

    06-19-2012 07:05 AM in reply to: samuel.pereira

    Wrong Params.

     

        RobApp.Project.Preferences.SetActiveCode I_CT_STEEL_STRUCTURES, "ENV 1993-1:2005"
    '.....
        Dim RDimMembParams As IRDimMembParamsE32

     

     



    Rafal Gaweda
    Product Support
    Autodesk, Inc.
    Please use plain text.
    Contributor
    samuel.pereira
    Posts: 22
    Registered: ‎01-02-2012

    Re: Robot Steel API - Member definition parameters

    06-19-2012 07:16 AM in reply to: RG_Adsk

    Ok! Already works! Thank you!

    Please use plain text.
    Contributor
    samuel.pereira
    Posts: 22
    Registered: ‎01-02-2012

    Re: Robot Steel API - Member definition parameters

    06-19-2012 09:29 AM in reply to: samuel.pereira

    Hello,

     

    At the moment, I have defined the member type. What remains now is to assign the type of member to the respective bar, in other words, assign the type "My Label" to a bar 1 and 2, for example. How do this? You can send an example?

     

    Thank you.

    Please use plain text.
    Product Support
    Posts: 2,731
    Registered: ‎04-26-2010

    Re: Robot Steel API - Member definition parameters

    06-20-2012 04:24 AM in reply to: samuel.pereira

    Like for all labels

     

    for one \ given bar number

     

    Dim Rbar As RobotBar
    Dim BarCollection As RobotBarCollection
    
    RobApp.Project.Structure.Bars.Get(bar_number).SetLabel I_LT_MEMBER_TYPE, "My Label"
    
    'or
    
    Set Rbar = RobApp.Project.Structure.Bars.Get(bar_number)
    Rbar.SetLabel I_LT_MEMBER_TYPE, "My Label"
    
    

     

    for bar collection

     

    Set RobotBarCollection = .........
    For i = 1 To BarCollection.Count
    
    BarCollection.Get(i).SetLabel I_LT_MEMBER_TYPE, "My Label"
    
    Next i

     



    Rafal Gaweda
    Product Support
    Autodesk, Inc.
    Please use plain text.