sketchucation logo sketchucation
    • Login
    1. Home
    2. schizo2000
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
    S
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 10
    • Groups 1

    schizo2000

    @schizo2000

    10
    Reputation
    1
    Profile views
    10
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    schizo2000 Unfollow Follow
    registered-users

    Latest posts made by schizo2000

    • RE: [REQ] Grasshopper for Sketchup

      posted in Plugins
      S
      schizo2000
    • RE: Read and Write (update) problem

      Thanks to every one here (and also Thomas Thomassen) the work is now finished!

      posted in Developers' Forum
      S
      schizo2000
    • RE: [REQ] Grasshopper for Sketchup

      It is going to be available soon!
      https://www.youtube.com/watch?v=xQOgv2OedJM

      posted in Plugins
      S
      schizo2000
    • RE: Read and Write (update) problem

      special thanks to you TIG, the timer was genius idea .

      posted in Developers' Forum
      S
      schizo2000
    • RE: Read and Write (update) problem

      Video of the process
      https://www.youtube.com/watch?v=EKKCQHfAUqk

      posted in Developers' Forum
      S
      schizo2000
    • RE: Read and Write (update) problem

      the problem is that I need the update-data in each cycle and the provider (the one that send the text files) is the one that decides when the reading action should stop. similar to web browsers when we want to get notified when sth changes.
      I am using the sleep to make the action less frequent in the hope of achieving more/better iterations.
      does that make sense? is there a better solution?

      posted in Developers' Forum
      S
      schizo2000
    • RE: Read and Write (update) problem

      well, we can change the sleep time (or we can omit it) but still 3-times reading is the best I can get out of this.

      posted in Developers' Forum
      S
      schizo2000
    • RE: Read and Write (update) problem

      thanks for your quick reply TIG.
      so the code would be sth like this:

      continuereading=0

      def reeed(continuereading)
      lines = IO.readlines("C:/GHConnection/temp.txt")
      return (lines[0]).to_i
      end

      while ((reeed (continuereading)))==1
      puts ('I am Reading the Source file')
      sleep(3)
      end

      it works fine but again it is 2 slow; all the characters in my text-file do not add up to 100 yet after iteration 3 the solution is practically worthless.

      posted in Developers' Forum
      S
      schizo2000
    • RE: Read and Write (update) problem

      by the way you should replace ContinueReading with continuereading

      the code would be:
      continuereading=0

      def reeed(continuereading)
      k=[]
      File.open("C:/GHConnection/temp.txt", "r") do |f|
      f.each_line do |e|
      k<<e
      end
      end
      continuereading= k[0].to_i

      puts (k[0])
      return continuereading
      end

      while reeed(continuereading)==1
      reeed(continuereading)
      puts ('I am Reading the Source file')
      sleep(3)
      break if reeed(continuereading)==0
      end

      posted in Developers' Forum
      S
      schizo2000
    • Read and Write (update) problem

      hello.
      I have a Ruby code that I want to use to gather data but it is to slow;
      does anybody know why>?

      ContinueReading=0

      def reeed(ContinueReading)
      k=[]
      File.open("C:/TT/temp.txt", "r") do |f|
      f.each_line do |e|
      k<<e
      end
      end
      ContinueReading=k[0].to_i
      puts (k[0])
      return ContinueReading
      end

      while reeed(ContinueReading)==1
      reeed(ContinueReading)
      puts ('I am Reading the Source file')
      sleep(3)
      break if reeed(ContinueReading)==0
      end

      posted in Developers' Forum
      S
      schizo2000