<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Working with loads on claddings (API) in Robot Structural Analysis Forum</title>
    <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3488988#M82332</link>
    <description>&lt;P&gt;OK, this flag is doing well.&lt;/P&gt;&lt;P&gt;It solves the question of accessing to a uniform load on a cladding.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now a last one : I wanted to extend this to a load defined by three points (&lt;EM&gt;IRobotLoadRecordIn3Points&lt;/EM&gt;). The flag is efficient as well but I have some trouble with the VBA code to get the coordinates of the points. The documentation suggests to use this method :&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Public Function GetPoint(_which_point As int, ByRef _x As double*, ByRef _y As double*, ByRef _z As double*) As Boolean&lt;/EM&gt;&lt;/P&gt;&lt;DIV class="Element101"&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;First remark :&amp;nbsp;when writing the code in the VBA Excel interface the type of the function is told to be a "long". It's not necessary a problem because the result of the function is no matter of interest.&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;But there is also a compilation error : even declaring explicitely the type of the three arguments x, y and z (&lt;EM&gt;Dim testX, testY, testZ As Double&lt;/EM&gt;), an error&amp;nbsp;message tells that the type of the ByRef arguments is incorrect when calling the function (after initializing an object as usual I just wrote :&amp;nbsp;&lt;EM&gt;LoadRec3p.GetPoint 1, testX, testY, testZ &lt;/EM&gt;guessing it would assign the coordinate values of point A to the last three arguments).&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;Do you have some example of a code properly writed in VBA ?...&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;Thanks for your help&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Thu, 07 Jun 2012 07:03:11 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2012-06-07T07:03:11Z</dc:date>
    <item>
      <title>Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3477230#M82328</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;During the last months of year 2011 I had a few discussions with Marcin Rakus and Marek Wiecek about how to manage with the load on claddings through the Robot Open Source API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The conclusion was that the API of RSA 2011 did not cover 100% of program functionality, making it impossible to manipulate such data. Typically,&amp;nbsp;when accessing the&amp;nbsp;load type I_LRT_UNIFORM associated to claddings in my RSA models, I get not only the loads on the cladding itself&amp;nbsp;but also the ones&amp;nbsp;generated automatically&amp;nbsp;on the bars being in the influence area of the cladding. The API seemed to work fine with&amp;nbsp;panels, unfortunately I do not use such objects.&amp;nbsp;We also tried to&amp;nbsp;write some&amp;nbsp;code to convert claddings into panels, and the opposite, but it did not lead&amp;nbsp;to something satisfying.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Has the API of RSA 2012 been updated to allow an efficient management of claddings ?...&lt;/P&gt;</description>
      <pubDate>Wed, 30 May 2012 12:21:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3477230#M82328</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-05-30T12:21:38Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3479056#M82329</link>
      <description>&lt;P&gt;I have not checked yet in code but according to documentation this flag is available from v.2012&lt;/P&gt;
&lt;P&gt;If IsAutoGenerated = true (1) such records can be skipped during ....&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;IMG src="https://forums.autodesk.com/t5/image/serverpage/image-id/29660iE1E3F8236D1BAFD1/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" alt="isauto.jpg" title="isauto.jpg" align="center" /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 31 May 2012 10:09:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3479056#M82329</guid>
      <dc:creator>Rafal.Gaweda</dc:creator>
      <dc:date>2012-05-31T10:09:53Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3485162#M82330</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ok I'll try to check in code, but how do you get access to this parameter ?&lt;/P&gt;&lt;P&gt;For example, working with a RobApp object initialized with Set RobApp = New RobotApplication : RobApp.Project.Structure... ???&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2012 10:26:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3485162#M82330</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-06-05T10:26:42Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3485638#M82331</link>
      <description>&lt;P&gt;Sample Excel VBA code:&lt;/P&gt;
&lt;P&gt;records with TRUE below displayed = generated automaticaly from cladding&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;IMG src="https://forums.autodesk.com/t5/image/serverpage/image-id/29958i03E48DD19E4DE12E/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" alt="autogen.jpg" title="autogen.jpg" align="center" /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Sub Button1_Click()
Dim RobApp As IRobotApplication
Set RobApp = New RobotApplication

Dim iscsel As IRobotSelection
Dim RLCom As IRobotLoadRecordCommon

Set iscsel = RobApp.Project.Structure.Selections.CreatePredefined(I_PS_CASE_SIMPLE_CASES)

Dim col As IRobotCaseCollection
Set col = RobApp.Project.Structure.Cases.GetMany(iscsel)
Dim isc As IRobotSimpleCase
Row = 10

For c = 1 To col.Count
    Range("B9").Value = Format(c) &amp;amp; " / " &amp;amp; Format(ccount)
    Dim icase As IRobotCase
    Set icase = col.Get(c)
    If icase.Type = I_CT_SIMPLE Then
        
        Set isc = icase
        Dim r As Long, i As Long, rcount As Long
        rcount = isc.Records.Count
        r = 1
        While r &amp;gt; 0 And r &amp;lt;= isc.Records.Count
            Rr = "B" + Trim(Str(Row))
            Range(Rr).Value = icase.Number &amp;amp; " / " &amp;amp; Format(isc.Records.Count)
            DoEvents
            Dim irec As IRobotLoadRecord
            Set irec = isc.Records.Get(r)
            Set RLCom = isc.Records.Get(r)
            
            Cells(Row, 3) = Str(RLCom.IsAutoGenerated)
            Cells(Row, 4) = irec.Objects.ToText

 
            Set irec = isc.Records.Get(r)
            For iic = 0 To 14
                Cells(Row, 5 + iic) = irec.GetValue(iic)
            Next iic
            Row = Row + 1
            r = r + 1
        Wend
        Set isc = Nothing
        
    End If

    Set icase = Nothing
Next c

Set col = Nothing
Set iscsel = Nothing
RobApp.Interactive = 1
Set RobApp = Nothing
End Sub&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2012 14:48:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3485638#M82331</guid>
      <dc:creator>Rafal.Gaweda</dc:creator>
      <dc:date>2012-06-05T14:48:45Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3488988#M82332</link>
      <description>&lt;P&gt;OK, this flag is doing well.&lt;/P&gt;&lt;P&gt;It solves the question of accessing to a uniform load on a cladding.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now a last one : I wanted to extend this to a load defined by three points (&lt;EM&gt;IRobotLoadRecordIn3Points&lt;/EM&gt;). The flag is efficient as well but I have some trouble with the VBA code to get the coordinates of the points. The documentation suggests to use this method :&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Public Function GetPoint(_which_point As int, ByRef _x As double*, ByRef _y As double*, ByRef _z As double*) As Boolean&lt;/EM&gt;&lt;/P&gt;&lt;DIV class="Element101"&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;First remark :&amp;nbsp;when writing the code in the VBA Excel interface the type of the function is told to be a "long". It's not necessary a problem because the result of the function is no matter of interest.&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;But there is also a compilation error : even declaring explicitely the type of the three arguments x, y and z (&lt;EM&gt;Dim testX, testY, testZ As Double&lt;/EM&gt;), an error&amp;nbsp;message tells that the type of the ByRef arguments is incorrect when calling the function (after initializing an object as usual I just wrote :&amp;nbsp;&lt;EM&gt;LoadRec3p.GetPoint 1, testX, testY, testZ &lt;/EM&gt;guessing it would assign the coordinate values of point A to the last three arguments).&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;Do you have some example of a code properly writed in VBA ?...&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="Element100"&gt;Thanks for your help&lt;/DIV&gt;&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 07 Jun 2012 07:03:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3488988#M82332</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-06-07T07:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3490708#M82333</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;DIV class="Element101"&gt;
&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&lt;EM&gt;First remark :&amp;nbsp;when writing the code in the VBA Excel interface the type of the function is told to be a "long". It's not necessary a problem because the result of the function is no matter of interest.&lt;/EM&gt;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;"Get coordinates of given point of load. Return false when given point has not "&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;In fact if false it returns 0, if true &amp;nbsp; -1. They can be long or bool.&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&lt;EM&gt;Do you have some example of a code properly writed in VBA ?...&lt;/EM&gt;&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV class="Element100"&gt;&lt;IMG src="https://forums.autodesk.com/t5/image/serverpage/image-id/30194iEAFA2AFB734862E0/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" alt="3p.jpg" title="3p.jpg" align="center" /&gt;&lt;/DIV&gt;
&lt;/BLOCKQUOTE&gt;
&lt;PRE&gt;Sub AAAA()
Dim RobApp As IRobotApplication
Set RobApp = New RobotApplication

Dim iscsel As IRobotSelection
Dim RLCom As IRobotLoadRecordCommon

Set iscsel = RobApp.Project.Structure.Selections.CreatePredefined(I_PS_CASE_SIMPLE_CASES)

Dim col As IRobotCaseCollection
Set col = RobApp.Project.Structure.Cases.GetMany(iscsel)
Dim isc As IRobotSimpleCase
Row = 10

For c = 1 To col.Count
    Set isc = col.Get(c)
   
        Dim r As Long, i As Long, rcount As Long
        rcount = isc.Records.Count
        For r = 1 To rcount
        
            Dim irec As IRobotLoadRecord
            Set irec = isc.Records.Get(r)
            
            If (irec.Type = I_LRT_IN_3_POINTS) Then
                Dim Cr As RobotLoadRecordIn3Points
                Set Cr = isc.Records.Get(r)
                Dim X As Double
                Dim Y As Double
                Dim Z As Double
                
                For i = 1 To 3
                    Cr.GetPoint i, X, Y, Z
                    Cells(Row, 3) = "Point " &amp;amp; Str(i)
                    Cells(Row, 4) = X
                    Cells(Row, 5) = Y
                    Cells(Row, 6) = Z
                    Cells(Row, 7) = "Value"
                    Cells(Row, 8) = Cr.GetValue(i * 3 - 3)
                    Cells(Row, 9) = Cr.GetValue(i * 3 - 2)
                    Cells(Row, 10) = Cr.GetValue(i * 3 - 1)
                    Row = Row + 1
                Next i
            End If
            
            Row = Row + 1
        Next r
      
        Set isc = Nothing

    Set icase = Nothing
Next c

Set col = Nothing
Set iscsel = Nothing
RobApp.Interactive = 1
Set RobApp = Nothing
End Sub&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jun 2012 22:22:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3490708#M82333</guid>
      <dc:creator>Rafal.Gaweda</dc:creator>
      <dc:date>2012-06-07T22:22:37Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3495930#M82334</link>
      <description>&lt;P&gt;Thanks for the example&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After looking for a long time for errors in the objects syntax (unsuccessfully), I found out quite by chance why&amp;nbsp;the compilation failed :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;when declaring variables I often use such a syntax to save time :&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Dim X, Y, Z as Double&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in Excel VBA this should not be different from :&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Dim X as Double&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Dim&amp;nbsp;Y as Double&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Dim&amp;nbsp;Z as Double&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;but&amp;nbsp;here the code does not run&amp;nbsp;when using the first method... don't understand why&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyway, this answers the whole question.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Jun 2012 10:16:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3495930#M82334</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-06-12T10:16:33Z</dc:date>
    </item>
    <item>
      <title>Re: Working with loads on claddings (API)</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3548050#M82335</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;BR /&gt;
&lt;P&gt;&lt;EM&gt;&amp;nbsp;We also tried to&amp;nbsp;write some&amp;nbsp;code to convert claddings into panels, and the opposite, but it did not lead&amp;nbsp;to something satisfying.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;        Dim r As New RobotOM.RobotApplication
        Dim o As RobotOM.RobotObjObject
        o = r.Project.Structure.Objects.Get(1)
        o.SetLabel(RobotOM.IRobotLabelType.I_LT_CLADDING, "Two-way")
        o.Update()
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;Most important &lt;FONT color="#339966"&gt;&amp;nbsp;o.Update() &lt;FONT color="#000000"&gt;at the end&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Mon, 23 Jul 2012 10:58:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/working-with-loads-on-claddings-api/m-p/3548050#M82335</guid>
      <dc:creator>Rafal.Gaweda</dc:creator>
      <dc:date>2012-07-23T10:58:40Z</dc:date>
    </item>
  </channel>
</rss>

