• Login
sketchucation logo sketchucation
  • Login
🤑 SketchPlus 1.3 | 44 Tools for $15 until June 20th Buy Now

Load plugin on condition of textfile

Scheduled Pinned Locked Moved Developers' Forum
2 Posts 1 Posters 5.8k Views
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.
  • U Offline
    UncleString
    last edited by 6 Dec 2018, 20:16

    I have an excel file that opens sketchup, creates the drawing, then closes sketchup.

    NOTE:
    I have changed my way of thinking, now before excel opens sketchup, it will change a word in a text file to "go", then when the plugin works it's magic, it will change the word in the textfile to "no go"

    It still seems to load the plugin even it the textfile is "no go"

    File.open("C:/TestFolder/Doit with Sketchup/RunPlugIn.txt").each do|line| puts line UI.messagebox line if line == "go" load "testOpenSketchup.rb" UI.messagebox "Go" elseif line=="no go" puts "Nope" end end

    1 Reply Last reply Reply Quote 0
    • U Offline
      UncleString
      last edited by 10 Dec 2018, 14:09

      Okay, I found a solution, I should have had the if statement in the plugin I wanted to run.

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

      Advertisement