<?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: Python Api in Robot Structural Analysis Forum</title>
    <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940868#M24645</link>
    <description>&lt;LI-CODE lang="general"&gt;Unhandled Exception: System.NotSupportedException: Cannot create uninitialized instances of types requiring managed activation.
   at System.Runtime.Serialization.FormatterServices.nativeGetUninitializedObject(RuntimeType type)
   at Python.Runtime.ClassObject.tp_new_impl(BorrowedReference tp, BorrowedReference args, BorrowedReference kw)
   at Python.Runtime.NativeCall.Call_3(IntPtr fp, BorrowedReference a1, BorrowedReference a2, BorrowedReference a3)
   at Python.Runtime.MetaType.tp_call(BorrowedReference tp, BorrowedReference args, BorrowedReference kw)&lt;/LI-CODE&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7613523"&gt;@JacquesGaudin&lt;/a&gt;Thank you for the response. I'm just learning the python integration with RSA, So I'm just using the limited threads and curious to see how python is calling the objects in RSA. Thanks for your time in advance &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 04 May 2023 09:18:28 GMT</pubDate>
    <dc:creator>ArunNDinesh</dc:creator>
    <dc:date>2023-05-04T09:18:28Z</dc:date>
    <item>
      <title>Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/8804010#M24633</link>
      <description>&lt;P&gt;Good morning!!!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When I try to define a support in Python with the follwoing code,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;sup = labels.Create(rp.IRobotLabelType.I_LT_SUPPORT, 'sup')&lt;BR /&gt;sup_dt=rp.IRobotNodeSupportData&lt;BR /&gt;sup_dt = sup.Data&lt;BR /&gt;sup_dt.UX = 1&lt;BR /&gt;sup_dt.UY = 1&lt;BR /&gt;sup_dt.UZ = 1&lt;BR /&gt;sup_dt.RX = 1&lt;BR /&gt;sup_dt.RY = 1&lt;BR /&gt;sup_dt.RZ = 1&lt;BR /&gt;labels.Store(sup)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I got the error:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;File "&amp;lt;ipython-input-56-8cf91e21e0e8&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;BR /&gt;sup_dt = sup.Data&lt;/P&gt;
&lt;P&gt;AttributeError: '__ComObject' object has no attribute 'Data'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can someone help me?&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 May 2019 08:51:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/8804010#M24633</guid>
      <dc:creator>cool.stuff</dc:creator>
      <dc:date>2019-05-21T08:51:01Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9510186#M24634</link>
      <description>&lt;P&gt;You can try casting the object returned by ``labels.Create`` to ``IRobotLabel`` to make sure it implements the Label interface. I do that often since I am running the code on CPython through PythonNet.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;sup = IRobotLabel(labels.Create(rp.IRobotLabelType.I_LT_SUPPORT, 'sup')

sup_dt = IRobotNodeSupportData(sup.Data)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That should solve the issue.&amp;nbsp;&lt;SPAN&gt;&lt;span class="lia-unicode-emoji" title=":crossed_fingers:"&gt;🤞&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 12 May 2020 15:07:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9510186#M24634</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2020-05-12T15:07:10Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749548#M24635</link>
      <description>&lt;P&gt;Many thanks for your answer and sorry for my late one!!!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried what you said but stil get an syntax error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;import clr&lt;BR /&gt;import math&lt;BR /&gt;import sys&lt;BR /&gt;import csv&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;clr.AddReference('C:\Program Files\Autodesk\Autodesk Robot Structural Analysis Professional 2019\System\Exe\Interop.RobotOM.dll')&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;import RobotOM as rbt&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;from System import Environment&lt;BR /&gt;from RobotOM import *&lt;BR /&gt;from System import Object&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;robapp=rbt.RobotApplicationClass()&lt;BR /&gt;struc=robapp.Project.Structure&lt;BR /&gt;node=struc.Nodes&lt;BR /&gt;bar=struc.Bars&lt;BR /&gt;labels=struc.Labels&lt;BR /&gt;stress=struc.Results.Bars.Stresses&lt;BR /&gt;force=struc.Results.Bars.Forces&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;sup = IRobotLabel(labels.Create(robapp.IRobotLabelType.I_LT_SUPPORT, 'createdSupport')&lt;BR /&gt;supData = IRobotNodeSupportData(sup.Data)&lt;BR /&gt;supData.UX = 1&lt;BR /&gt;supData.UY = 1&lt;BR /&gt;supData.UZ = 1&lt;BR /&gt;supData.RX = 1&lt;BR /&gt;supData.RY = 1&lt;BR /&gt;supData.RZ = 1&lt;BR /&gt;labels.Store(sup)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any aideas why?&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 07:44:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749548#M24635</guid>
      <dc:creator>cool.stuff</dc:creator>
      <dc:date>2020-09-16T07:44:45Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749640#M24636</link>
      <description>&lt;P&gt;Please include the full error message including line number. It makes it much easier to spot the mistake. It may just be a typo so please copy exactly the code you are trying to run.&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 08:41:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749640#M24636</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2020-09-16T08:41:25Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749665#M24637</link>
      <description>&lt;P&gt;Many thanks for your answer!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My full code (the is like this one):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;import clr&lt;BR /&gt;import math&lt;BR /&gt;import sys&lt;BR /&gt;import csv&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;clr.AddReference('C:\Program Files\Autodesk\Autodesk Robot Structural Analysis Professional 2019\System\Exe\Interop.RobotOM.dll')&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;import RobotOM as rbt&lt;/P&gt;&lt;P&gt;from System import Environment&lt;BR /&gt;from RobotOM import *&lt;BR /&gt;from System import Object&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;robapp=rbt.RobotApplicationClass()&lt;BR /&gt;struc=robapp.Project.Structure&lt;BR /&gt;node=struc.Nodes&lt;BR /&gt;bar=struc.Bars&lt;BR /&gt;labels=struc.Labels&lt;BR /&gt;stress=struc.Results.Bars.Stresses&lt;BR /&gt;force=struc.Results.Bars.Forces&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sup = IRobotLabel(labels.Create(robapp.IRobotLabelType.I_LT_SUPPORT, 'createdSupport')&lt;BR /&gt;supData = IRobotNodeSupportData(sup.Data)&lt;BR /&gt;supData.UX = 1&lt;BR /&gt;supData.UY = 1&lt;BR /&gt;supData.UZ = 1&lt;BR /&gt;supData.RX = 1&lt;BR /&gt;supData.RY = 1&lt;BR /&gt;supData.RZ = 1&lt;BR /&gt;labels.Store(sup)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;runfile('G:/WIP/RSAP Python/RSAP_Test.py', wdir='G:/WIP/RSAP Python')&lt;BR /&gt;Traceback (most recent call last):&lt;/P&gt;&lt;P&gt;File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\IPython\core\interactiveshell.py", line 2963, in run_code&lt;BR /&gt;exec(code_obj, self.user_global_ns, self.user_ns)&lt;/P&gt;&lt;P&gt;File "&amp;lt;ipython-input-2-727407a95006&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;BR /&gt;runfile('G:/WIP/RSAP Python/RSAP_Test.py', wdir='G:/WIP/RSAP Python')&lt;/P&gt;&lt;P&gt;File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 827, in runfile&lt;BR /&gt;execfile(filename, namespace)&lt;/P&gt;&lt;P&gt;File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 110, in execfile&lt;BR /&gt;exec(compile(f.read(), filename, 'exec'), namespace)&lt;/P&gt;&lt;P&gt;File "G:/WIP/RSAP Python/RSAP_Test.py", line 45&lt;BR /&gt;supData = IRobotNodeSupportData(sup.Data)&lt;BR /&gt;^&lt;BR /&gt;SyntaxError: invalid syntax&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is what I get..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 08:57:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749665#M24637</guid>
      <dc:creator>cool.stuff</dc:creator>
      <dc:date>2020-09-16T08:57:16Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749675#M24638</link>
      <description>There is a bracket missing at the end of&lt;BR /&gt;&lt;BR /&gt;sup = IRobotLabel(labels.Create(robapp.IRobotLabelType.I_LT_SUPPORT, 'createdSupport')&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 16 Sep 2020 08:58:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749675#M24638</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2020-09-16T08:58:53Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749676#M24639</link>
      <description>&lt;P&gt;There is a closing bracket missing at the end of:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;sup = IRobotLabel(labels.Create(robapp.IRobotLabelType.I_LT_SUPPORT, 'createdSupport')&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 08:59:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749676#M24639</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2020-09-16T08:59:25Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749679#M24640</link>
      <description>&lt;P&gt;Many thanks!!! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What a silly mistake -.-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But now I get the following error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sup = IRobotLabel(labels.Create(robapp.IRobotLabelType.I_LT_SUPPORT, 'createdSupport'))&lt;/P&gt;&lt;P&gt;AttributeError: 'RobotApplicationClass' object has no attribute 'IRobotLabelType'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've changed to sup = IRobotLabel(labels.Create(robapp.IRobotLabel.I_LT_SUPPORT, 'createdSupport')) but stil get the same..&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 09:02:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749679#M24640</guid>
      <dc:creator>cool.stuff</dc:creator>
      <dc:date>2020-09-16T09:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749700#M24641</link>
      <description>&lt;P&gt;In fairness, the error was mine in the original answer&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;IRobotLabelType is in the RobotOM module so it should be:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;sup = IRobotLabel(labels.Create(RobotOM.IRobotLabelType.I_LT_SUPPORT, 'createdSupport'))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;or since you import * from RobotOM:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;sup = IRobotLabel(labels.Create(IRobotLabelType.I_LT_SUPPORT, 'createdSupport'))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note if you want to look at the list of names defined in an object or module, you can use:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dir(myObject)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dir(myModule)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It helps locating things as the API documentation is sometimes incomplete.&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 09:12:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749700#M24641</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2020-09-16T09:12:14Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749709#M24642</link>
      <description>&lt;P&gt;Works like a charm!!! :))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks for solving and for teaching a few useful tricks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You're the man!!! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Sep 2020 09:15:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/9749709#M24642</guid>
      <dc:creator>cool.stuff</dc:creator>
      <dc:date>2020-09-16T09:15:33Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940568#M24643</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5952516"&gt;@cool.stuff&lt;/a&gt;&amp;nbsp;Can you please share the final code which is working? I just budding some python integration with RSA. The code in the thread is not working for me.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;import clr
import math
import sys
import csv
clr.AddReference('C:\Program Files\Autodesk\Robot Structural Analysis Professional 2023\Exe\Interop.RobotOM.dll')
import RobotOM as rbt
from System import Environment
from RobotOM import *
from System import Object
robapp=rbt.RobotApplicationClass()
struc=robapp.Project.Structure

RobApp  = RobotApplicationClass() # Connect to  Robot Structural Analysis
RobProj = RobApp.Project # To Get current project
RobStruc = RobProj.Structure # To Get current model

node=RobStruc.Nodes
bar=RobStruc.Bars
labels=RobStruc.Labels
stress=RobStruc.Results.Bars.Stresses
force=RobStruc.Results.Bars.Forces

sup = IRobotLabel(labels.Create(RobotOM.IRobotLabelType.I_LT_SUPPORT, 'Sup'))
supData = IRobotNodeSupportData(sup.Data)
supData.UX = 1
supData.UY = 1
supData.UZ = 1
supData.RX = 1
supData.RY = 1
supData.RZ = 1
labels.Store(sup)&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 04 May 2023 06:44:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940568#M24643</guid>
      <dc:creator>ArunNDinesh</dc:creator>
      <dc:date>2023-05-04T06:44:23Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940860#M24644</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/9629849"&gt;@ArunNDinesh&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please post the error message, we need to know how it's not working to help you.&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 09:10:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940860#M24644</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2023-05-04T09:10:07Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940868#M24645</link>
      <description>&lt;LI-CODE lang="general"&gt;Unhandled Exception: System.NotSupportedException: Cannot create uninitialized instances of types requiring managed activation.
   at System.Runtime.Serialization.FormatterServices.nativeGetUninitializedObject(RuntimeType type)
   at Python.Runtime.ClassObject.tp_new_impl(BorrowedReference tp, BorrowedReference args, BorrowedReference kw)
   at Python.Runtime.NativeCall.Call_3(IntPtr fp, BorrowedReference a1, BorrowedReference a2, BorrowedReference a3)
   at Python.Runtime.MetaType.tp_call(BorrowedReference tp, BorrowedReference args, BorrowedReference kw)&lt;/LI-CODE&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7613523"&gt;@JacquesGaudin&lt;/a&gt;Thank you for the response. I'm just learning the python integration with RSA, So I'm just using the limited threads and curious to see how python is calling the objects in RSA. Thanks for your time in advance &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 09:18:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11940868#M24645</guid>
      <dc:creator>ArunNDinesh</dc:creator>
      <dc:date>2023-05-04T09:18:28Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11941433#M24646</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/9629849"&gt;@ArunNDinesh&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is rather unusual! Do you know which line triggers the error?&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 13:33:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11941433#M24646</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2023-05-04T13:33:41Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11943155#M24647</link>
      <description>&lt;P&gt;I do have issues in these many lines. I don't know what is the reason and got stuck!!&lt;/P&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7613523"&gt;@JacquesGaudin&lt;/a&gt;&amp;nbsp;Please help if you know . . .&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="andi4G4Z4_0-1683260219313.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1210757i4F9D6D2E5A2CD025/image-size/medium?v=v2&amp;amp;px=400" role="button" title="andi4G4Z4_0-1683260219313.png" alt="andi4G4Z4_0-1683260219313.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 May 2023 04:17:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11943155#M24647</guid>
      <dc:creator>ArunNDinesh</dc:creator>
      <dc:date>2023-05-05T04:17:09Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11943502#M24648</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/9629849"&gt;@ArunNDinesh&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to understand which line causes the error. Could you add some print statements in your code to establish where it stops?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The messages saying the import cannot be resolved look like warnings emitted by your IDE, I wouldn't worry to much about them for now.&lt;/P&gt;</description>
      <pubDate>Fri, 05 May 2023 08:41:05 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11943502#M24648</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2023-05-05T08:41:05Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11948604#M24649</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7613523"&gt;@JacquesGaudin&lt;/a&gt;&amp;nbsp;I already copied the print statements. It seems the issue starts from Line 6. Is this working for you?&lt;SPAN&gt;&lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="andi4G4Z4_0-1683538754669.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1211680i4515655B391D4832/image-size/medium?v=v2&amp;amp;px=400" role="button" title="andi4G4Z4_0-1683538754669.png" alt="andi4G4Z4_0-1683538754669.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I am able to open ROBOT application using&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;import&lt;/SPAN&gt; &lt;SPAN&gt;subprocess&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;file&lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&lt;SPAN&gt;subprocess&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;Popen&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'C:&lt;/SPAN&gt;&lt;SPAN&gt;\\&lt;/SPAN&gt;&lt;SPAN&gt;Program Files&lt;/SPAN&gt;&lt;SPAN&gt;\\&lt;/SPAN&gt;&lt;SPAN&gt;Autodesk&lt;/SPAN&gt;&lt;SPAN&gt;\\&lt;/SPAN&gt;&lt;SPAN&gt;Robot Structural Analysis Professional 2023&lt;/SPAN&gt;&lt;SPAN&gt;\\&lt;/SPAN&gt;&lt;SPAN&gt;Exe&lt;/SPAN&gt;&lt;SPAN&gt;\\&lt;/SPAN&gt;&lt;SPAN&gt;robot.exe'&lt;/SPAN&gt;&lt;SPAN&gt;) and there is no issue. But unable to integrate other functions with ROBOT&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 08 May 2023 09:44:24 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11948604#M24649</guid>
      <dc:creator>ArunNDinesh</dc:creator>
      <dc:date>2023-05-08T09:44:24Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11951182#M24650</link>
      <description>&lt;P&gt;What I mean by print statements in the code is to add some lines in the like of ```print('Robot import successful')``` after each line of your script.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;import clr
print('clr imported')

clr.Addreference(&amp;lt;your path&amp;gt;)
print('Reference to Robot added')

import RobotOM
print('Robot imported')
...&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This will tell you on which line the program stops.&lt;/P&gt;</description>
      <pubDate>Tue, 09 May 2023 10:09:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11951182#M24650</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2023-05-09T10:09:19Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11951384#M24651</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/7613523"&gt;@JacquesGaudin&lt;/a&gt;&amp;nbsp;Thank you for the clarification. Added the print statement and it seems like line 19 is having the issue.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="andi4G4Z4_0-1683632687022.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1212189i699E16D4E0185BAF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="andi4G4Z4_0-1683632687022.png" alt="andi4G4Z4_0-1683632687022.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;import clr
print('clr imported')
import math
print('math imported')
import sys
print('sys imported')
import csv
print('csv imported')
clr.AddReference('C:\Program Files\Autodesk\Robot Structural Analysis Professional 2023\Exe\Interop.RobotOM.dll')
print('Reference to Robot added')
import RobotOM as rbt
print('Robot imported 1')
from System import Environment
print('imported 2')
from RobotOM import *
print('imported 3')
from System import Object
print('imported 4')
robapp=rbt.RobotApplicationClass()
print('imported 5')
struc=robapp.Project.Structure
print('imported 6')

RobApp  = RobotApplicationClass() # Connect to  Robot Structural Analysis
print('imported 7')
RobProj = RobApp.Project # To Get current project
print('imported 8')
RobStruc = RobProj.Structure # To Get current model
print('imported 9')

node=RobStruc.Nodes
bar=RobStruc.Bars
labels=RobStruc.Labels
stress=RobStruc.Results.Bars.Stresses
force=RobStruc.Results.Bars.Forces

sup = IRobotLabel(labels.Create(RobotOM.IRobotLabelType.I_LT_SUPPORT, 'Sup'))
supData = IRobotNodeSupportData(sup.Data)
supData.UX = 1
supData.UY = 1
supData.UZ = 1
supData.RX = 1
supData.RY = 1
supData.RZ = 1
labels.Store(sup)&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 09 May 2023 11:46:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11951384#M24651</guid>
      <dc:creator>ArunNDinesh</dc:creator>
      <dc:date>2023-05-09T11:46:28Z</dc:date>
    </item>
    <item>
      <title>Re: Python Api</title>
      <link>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11952211#M24652</link>
      <description>&lt;P&gt;Interesting! I usually get the RobotApplication from:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;RobApp  = RobotApplication()&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;rather than RobotApplicationClass(). Does that solve the issue?&lt;/P&gt;</description>
      <pubDate>Tue, 09 May 2023 17:00:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/robot-structural-analysis-forum/python-api/m-p/11952211#M24652</guid>
      <dc:creator>JacquesGaudin</dc:creator>
      <dc:date>2023-05-09T17:00:08Z</dc:date>
    </item>
  </channel>
</rss>

