Topic
  • 2 replies
  • Latest Post - ‏2019-05-22T07:30:56Z by payf
WalterVanDerHeiden
WalterVanDerHeiden
86 Posts

Pinned topic Python scripts with Rhapsody

‏2019-04-04T13:25:19Z |

Hi!

 

Is it possible to access Rhapsody's API via Python?

 

Walter

  • Giri Kolanupaka
    Giri Kolanupaka
    2 Posts

    Re: Python scripts with Rhapsody

    ‏2019-04-15T15:16:01Z  

    It is very much possible with any language that supports Windows COM. If you use python win32com, and rest is all by using Rhapsody COM Api

     

    I have a small python snippet:

     

    import pythoncom
    import win32com.client

    rhapsody = win32com.client.gencache.EnsureDispatch("Rhapsody.Application")

    project = rhapsody.activeProject()  #project = rhapsody.openProject(prj_path)

     

     

  • payf
    payf
    57 Posts

    Re: Python scripts with Rhapsody

    ‏2019-05-22T07:30:56Z  

    It is very much possible with any language that supports Windows COM. If you use python win32com, and rest is all by using Rhapsody COM Api

     

    I have a small python snippet:

     

    import pythoncom
    import win32com.client

    rhapsody = win32com.client.gencache.EnsureDispatch("Rhapsody.Application")

    project = rhapsody.activeProject()  #project = rhapsody.openProject(prj_path)

     

     

    Hi Giri,

    interesting... did you maybe try more towards rhapsody plugins with python (including hep files etc). 

    Regards,

    Pablo