sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    Interprocess communication

    Scheduled Pinned Locked Moved Developers' Forum
    3 Posts 2 Posters 236 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P Offline
      pdonner
      last edited by

      So... made a jump from Newbies to the forum of the big boys: Developers' Forum. - I'm interested in ways of controlling SU externally and in ways of communicating with another app from SU.

      I would basically like to write a conversion between PPT diagrams and a simple top view of similar SU objects, which would enable me to make nice renderings of the diagrams by using SU styles and 3D rendering methods.

      This kind of interprocess communication can of course be handled by putting out a csv file, which would describe the diagram entities. This file could then be handled by a SU plugin. Someone seems to be writing ruby temp files which are activated as a SU command line argument or a ruby load. Then there is the possibility of embedding scripts in a WebDialog, and so forth.

      Basically I would like to study in what ways SU and Windows automation can work together in an intimate way; ideally in a way whereby changes in one app (now PPT) would be reflected in the other (SU).

      What are the best method of creating this kind of an interconnection?

      1 Reply Last reply Reply Quote 0
      • Dan RathbunD Offline
        Dan Rathbun
        last edited by

        look into Win32OLE.so

        http://phrogz.net/ProgrammingRuby/lib_windows.html#WIN32OLE
        and
        http://phrogz.net/ProgrammingRuby/win32.html#rubyandmicrosoftwindows
        slide down to "Windows Automation"

        get win32ole.so and win32api.so here

        I'm not here much anymore.

        1 Reply Last reply Reply Quote 0
        • P Offline
          pdonner
          last edited by

          Thanks, Dan. Your advice was very useful. I could have lost a lot of time on the other schemes which I referred to. The 'Programming Ruby' book by David Thomas and Andrew Hunt looks interesting.

          Downloaded the .so extension modules, installed them and run a Ruby console session:

          >require 'win32ole'
           true
          
          >ppt = WIN32OLE.new("PowerPoint.Application")
          #<WIN32OLE;0x11396c58>
          
          >ppt.Activate
          nil
          

          That's it: PowerPoint was activated, so I'm ready to use PPT automation in a SU script as desired. Really elegant.

          This scheme depends on the WIN32OLE extension written by Masaki Suketa. Can anybody give me advice on standard procedures for installation of such extensions on the machines of SU users.

          My post had another aspect: We are now capable of using Ruby as a client for Windows Automation. What about the other direction. Can SU be extended to become an automation server?

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post
          Buy SketchPlus
          Buy SUbD
          Buy WrapR
          Buy eBook
          Buy Modelur
          Buy Vertex Tools
          Buy SketchCuisine
          Buy FormFonts

          Advertisement