• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Autodesk Robot Structural Analysis

    Reply
    Distinguished Contributor
    mateaus
    Posts: 117
    Registered: ‎10-10-2011
    Accepted Solution

    VBA cases and combinations

    136 Views, 2 Replies
    11-18-2011 01:25 AM

    Hi

     

    I already create cases in my model and I would like to add cases with VBA to this one.

     

    3 : equipements

     

    I only know this command but it create new cases.

     

    Set cas = robapp.Project.Structure.Cases.CreateSimple(robapp.Project.Structure.Cases.FreeNumber, _

    casdecharge, typecharge, I_CAT_STATIC_LINEAR)

     

    Can you give the command to select cases in order to define new loads ?

     

    I'd like also to create combinations like ?

     

    type : linear

    nature of case ELS

    name COMB1

    number 101

    0.5 * 1 + 1 * 2 + 6 * 3

     

    How can I make it ?

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

    Re: VBA cases and combinations

    11-18-2011 03:43 AM in reply to: mateaus

    Code for creating combination

     

    Dim Loads As RobotCaseServer
    Set Loads = RobApp.Project.Structure.Cases


    Dim cmb As RobotCaseCombination
    Set cmb = Loads.CreateCombination(110, "COMB1", I_CBT_ALS, I_CN_EXPLOATATION, I_CAT_COMB)
    cmb.CaseFactors.New 1, 0.3
    cmb.CaseFactors.New 2, 1
    cmb.CaseFactors.New 6, 1



    Rafal Gaweda
    Product Support
    Autodesk, Inc.
    Please use plain text.
    Product Support
    Posts: 2,515
    Registered: ‎04-26-2010

    Re: VBA cases and combinations

    11-18-2011 03:50 AM in reply to: RG_Adsk

    Seleting case for eg adding loads:

     

    Dim Loads As RobotCaseServer
    Set Loads = RobApp.Project.Structure.Cases


     Dim RCase As RobotSimpleCas

    Set RCase = Loads.Get(3)      '/ where 3 is real case number 

     

    then create and set records for RCase



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