sketchucation logo sketchucation
    • Login
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    πŸ«› Lightbeans Update | Metallic and Roughness auto-applied in SketchUp 2025+ Download

    Reloading plugins while SketchUp is running

    Scheduled Pinned Locked Moved Developers' Forum
    5 Posts 3 Posters 2.1k Views 3 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.
    • J Offline
      JaViXP
      last edited by

      @thomthom said:

      @javixp said:

      is is possible to load/unload/reload plugins with SketchUp running?

      You can load (and reload) scripts by using the Ruby Console, typing load 'myRubyFile.rb'

      I tried that and it worked. However, what I wanted was to reload plugins using... another plugin, something like this:

      def reload load 'myRubyFile.rb' end

      Problem is that one doesn't work, the Ruby Console says:

      C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64;in `load'
      C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64
      C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64;in `call'
      C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64
      

      Note: Line 64 is where the function 'reload' is called

      Thanks

      "Giving up is way harder than trying"
      JaViXP's Rendering

      1 Reply Last reply Reply Quote 0
      • thomthomT Offline
        thomthom
        last edited by

        You must replace myRubyFile.rb with the actual filename of the plugin you want to reload. I just picked a random name...

        Thomas Thomassen β€” SketchUp Monkey & Coding addict
        List of my plugins and link to the CookieWare fund

        1 Reply Last reply Reply Quote 0
        • J Offline
          JaViXP
          last edited by

          I know, I know. I think you didn't understand me well 😳

          It does work on the ruby console, but not as a plugin itself.

          "Giving up is way harder than trying"
          JaViXP's Rendering

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

            You cannot load the file itself while it's being loaded. (.. it's a circular reference.)

            The load call must be made from another file.

            I'm not here much anymore.

            1 Reply Last reply Reply Quote 0
            • J Offline
              JaViXP
              last edited by

              That fixed the 'issue', thanks πŸ‘

              "Giving up is way harder than trying"
              JaViXP's Rendering

              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