| Author |
Message |
Stanley
Guest
|
Posted:
Fri Jan 07, 2005 12:14 pm Post subject:
How to Transfer objects from Layout to Model? |
|
|
Hello everybody,
Let me explain my problem here and wish someone can give some advice about
it.
I make use of Autocad's layout features very often, usually I have about 20
layout pages and each page contains up to 6 viewports in my drawing.
Dimensions / Title Blocks and some other Texts or Marks were all placed on
PaperSpace.
Now I need to transfer every Layout Page into the ModelSpace and save it as
separate drawing files.
The most important thing is to retain the same layout structure, but things
in each viewport must be extracted as entities and placed
into ModelSpace.
Thanks for help.
Best regards.
Stanley.
|
|
| Back to top |
|
 |
HJohn
Guest
|
Posted:
Sat Jan 08, 2005 12:09 am Post subject:
Re: How to Transfer objects from Layout to Model? |
|
|
| I am not sure if you can accomplish this at all, in an efficient way, but it would be very interesting to see if you can find a way. There is no method to add entities to the model space without providing required parameters, so you would have to create an entity reference (variable) for each entity you have in PS and store their properties. You could then add them to MS, but you still have to figure out the coordinate system relationship between MS and PS. After, you could delete everything from PS. Good luck. |
|
| Back to top |
|
 |
Stanley
Guest
|
Posted:
Sat Jan 08, 2005 11:42 am Post subject:
Re: How to Transfer objects from Layout to Model? |
|
|
Hello John,
Thanks for your advice.
Actually I'm using VBA routine to do the job. The result is acceptable but
slow & seems a bit complex.
My procedures are as follow:
1. Create a new document by VBA code first.
2. Collect all Viewport objects on the LayoutPage.
3. For each Viewport, Get it's Center & Boundary in PS coordinate.
Translate the Center &
Boundary coordinate into MS world coordinate.
Use the translated coordinate as a window for selecting objects
within the Viewport in MS.
4. Copy selected objects from Current Drawing to the New Document.
Move Objects from translated WCS of Viewport's center to the
Viewport's center in PS coordinate.
So that the layout structure can be retained.
5. After all Viewports were processed. Collect all entities on
LayoutPage's PS (except Viewport objects)
and copy them to the New Document also.
The above procedures have been written in VBA and works.
The problem is how to clip the objects that crossed by the Viewport
boundary?
Hope someone can provide a more simple & efficent way to do that.
|
|
| Back to top |
|
 |
krispy
Guest
|
Posted:
Mon Jan 10, 2005 3:17 am Post subject:
Re: How to Transfer objects from Layout to Model? |
|
|
| Have you looked at using the express tools command CHSPACE which moves objects from paperspace to modelspace and vice versa? |
|
| Back to top |
|
 |
Stanley
Guest
|
Posted:
Mon Jan 10, 2005 5:10 am Post subject:
Re: How to Transfer objects from Layout to Model? |
|
|
| Is it available and works with AutoCad2004? |
|
| Back to top |
|
 |
Matt W
Guest
|
Posted:
Mon Jan 10, 2005 9:57 pm Post subject:
Re: How to Transfer objects from Layout to Model? |
|
|
It's part of the Express Tools and yes, it's available in 2004.
--
I support two teams: The Red Sox and whoever beats the Yankees.
"Stanley" <KW_Chan@FengChuan.com.hk> wrote in message
news:41e1c80e_2@newsprd01...
| Quote: | Is it available and works with AutoCad2004?
|
|
|
| Back to top |
|
 |
|
|
|
|