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

    How to update facearea() calculation in DC without redraw?

    Scheduled Pinned Locked Moved Dynamic Components
    sketchup
    3 Posts 2 Posters 8.0k 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.
    • A Offline
      antioche
      last edited by

      Hi,
      I noticed that the facearea() calculation in dynamic components gets updated automatically on rescale of a dynamic component.

      However, when that component is edited (modifying its geometry to make surfaces larger, for instance, it does not get updated automatically, unless the dynamic component is then redrawn manually (context menu > dynamic components> redraw).

      This is fine and I could simply add a redraw() action on click interaction, but this unfortunately creates complications for me, as each dynamic component (a room) contains dynamic component windows and a redraw of the room component actually makes each window DC it contains unique (even though they are the same and should remain so, for window scheduling purpose).

      So my question is: is there a way to force this facearea() recalculation in a dynamic component without redrawing it? With Ruby maybe?

      Any help on this would be much appreciated.
      Cheers,

      Antioche

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

        I believe that one has to scale definition (via context menu) first then do the redraw to correctly report the area in the DC after a change in lenx,y, or z. (which in DCs is same as a scale operation)

        If you scale definition, then change a dummy or another attribute the DC will update

        example attached


        area_cal.skp

        1 Reply Last reply Reply Quote 0
        • A Offline
          antioche
          last edited by

          Hi pcmoor,
          Many thanks for the reply and example files.
          Yes, that is a nice trick that works: changing any parameter in the component option window and clicking apply will update the calculation without redraw.

          Cheers!

          A.

          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