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

    Deleted Shadow Info???

    Scheduled Pinned Locked Moved Developers' Forum
    4 Posts 3 Posters 321 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.
    • Al HartA Offline
      Al Hart
      last edited by

      I started a new drawing, and got an error in one of my ruby files because I was trying to access deleted shadow info. I'll never be able to repeat it again. Here is what happens when I try to access shadow info from the ruby console:

      
      model = Sketchup.active_model
      #<Sketchup;;Model;0xe789620>
      si = model.shadow_info
      #<Deleted Entity;0xe7872e0>
      
      

      It reports the SketchUp Shadow Info as a deleted entity.
      (This was right after starting a new model)

      1. Has anyone ever seen a case where the shadow info was deleted?

      2. Even though it may never happen again, I like to add check to Ruby Files so they don't die when something goes wrong. Does anyone know how to check for a "Deleted Entity". If so, I could avoid trying to access the shadow info when is was deleted.

      Al Hart

      http:wiki.renderplus.comimageseefRender_plus_colored30x30%29.PNG
      IRender nXt from Render Plus

      1 Reply Last reply Reply Quote 0
      • R Offline
        RickW
        last edited by

        1. I've had that happen with the Pages object, the Layers object, the Definitions object, and I think the View object. It's a strange situation and I haven't been able to reproduce it consistently.

        2. Did you try the .valid? method?

        RickW
        [www.smustard.com](http://www.smustard.com)

        1 Reply Last reply Reply Quote 0
        • scottliningerS Offline
          scottlininger
          last edited by

          Al,

          Are you on a mac or PC?

          • Scott Lininger
            SketchUp Software Engineer
            Have you visited the Ruby API Docs?
          1 Reply Last reply Reply Quote 0
          • Al HartA Offline
            Al Hart
            last edited by

            I was on a PC.

            I'll try the valid check. I can create an ordinary deleted entity - by deleting one - but I would still like to know how this state happens.

            Al Hart

            http:wiki.renderplus.comimageseefRender_plus_colored30x30%29.PNG
            IRender nXt from Render Plus

            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