Author Topic: Dynamic Block in Paper Space reacting to viewport?  (Read 5796 times)

0 Members and 1 Guest are viewing this topic.

surveyor_randy

  • Guest
Dynamic Block in Paper Space reacting to viewport?
« on: December 24, 2007, 11:56:10 AM »
Is it possible to have a dynamic block that is in paperspace, but not in a viewport, retrieve the twist and scale of a viewport?  I have a feeling the answer is no and that I'll have to come up with a vba solution.  Happy Holidays everyone!

Mark

  • Custom Title
  • Seagull
  • Posts: 28762
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #1 on: December 24, 2007, 02:36:57 PM »
I can't see anyway to retrieve the twist but the the scale is fairly simple using an attribute and field.

vp scale
http://www.theswamp.org/screens/mark/shot-0231.png

twist
http://www.theswamp.org/screens/mark/shot-0229.png
TheSwamp.org  (serving the CAD community since 2003)

surveyor_randy

  • Guest
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #2 on: December 24, 2007, 07:33:13 PM »
I can't see anyway to retrieve the twist but the the scale is fairly simple using an attribute and field.

vp scale
http://www.theswamp.org/screens/mark/shot-0231.png

twist
http://www.theswamp.org/screens/mark/shot-0229.png


Do you know how to get a dynamic block to react based on that particular value?  (VP scale)  I created a graphic scale bar with different visibility states based on a user selected scale.  It would be nice to tie it into the viewport scale.

I guess I could always resort to having the scale bar place inside the viewport, but I don't like having drawings with north arrows and scales all over model space.

ronjonp

  • Needs a day job
  • Posts: 7527
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #3 on: December 24, 2007, 08:12:07 PM »
Maybe this will help you...I put it together to ensure all north arrows would match the twist angles of all viewports.

http://www.theswamp.org/index.php?topic=19285.0

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

surveyor_randy

  • Guest
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #4 on: December 26, 2007, 05:18:30 PM »
Thanks guys.....

Ronjonp, that code looks pretty interesting and I think that I looked at it once before.  Your solution is a good one, but I would really like to design a dynamic block that would be linked to a viewport and react based on the settings of that viewport.  It doesn't look like what I would like to accomplish is possible (yet).  But I absolutely love working with dynamic blocks ever since I took the time to learn how they work!

I hope everyone here had an excellent Holiday!  The only thing that I got for Christmas was a bad hangover but hey, who's complaining!  :-D

T.Willey

  • Needs a day job
  • Posts: 5251
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #5 on: December 26, 2007, 05:23:41 PM »
You might be able to do it with reactors, but I'm not sure if DB's will allow it.  DB's might change each time you change the visible property, and such would break reactors attached to said DB, but that is a guess.
Tim

I don't want to ' end-up ', I want to ' become '. - Me

Please think about donating if this post helped you.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #6 on: December 29, 2007, 10:12:51 AM »
I think that you can achieve close to what you are after using layout tabs in your DWT. (using the Plan Production tools in C3D)
I think Fields and Formulas will fill in the Bar Scale numbers for you.
Be your Best


Michael Farrell
http://primeservicesglobal.com/

surveyor_randy

  • Guest
Re: Dynamic Block in Paper Space reacting to viewport?
« Reply #7 on: December 30, 2007, 11:13:59 AM »
Thanks for the suggestions!  Have a happy new year everyone!

I've looked into everyone's solutions and it looks like the only way to achieve my goal would be with a VBA routine to insert the block and retrieve the information I need from the viewport.