AutoCAD Map 3D General Discussion

AutoCAD Map 3D General Discussion

Reply
Member
christer.justusson
Posts: 3
Registered: ‎12-13-2010
Message 1 of 7 (757 Views)
Accepted Solution

How to convert mpolygons to polylines

757 Views, 6 Replies
11-27-2013 06:08 AM

Hello

I'm in search of a way to convert mpolygon objects to polylines in a way so they stay on its original layer. We use Layer Explode (lexplode) from Vianova but it doesn't work with Autocad Map 3D and they are not planning to develop it.

Most grateful for any answers.

 

 

 

Hello from France

 

When doing MAPIMPORT (from Surfaces / Closed Polygons) very often we have a very few MPOLYGONS (for example : Parcels/Buildings)

So I import surface object (like Parcels ou Buildings) with the option Creating standard Plines DISABLED !

 

But in fact 99.9 / 99.99% of the objects could be standard closed Plines ...

 

So I have a marvellous/beautiful French VLisp routine (written by a French developper) which analyses MPOLYGONs and if it's MPolygons (without any holes, and NOT multiple) the routine will create a good old closed Pline and then copy ODs (with COPY_OD.lsp routine) from the MPolygons to the created closed Pline !

And if you want the old MPolygons are deleted because now we have a Closed Plines ...

 

Do you want this routine ???

 

It's very very useful !!

 

Bye, Pat

 

 

Valued Mentor
parkr4st
Posts: 451
Registered: ‎03-24-2004
Message 2 of 7 (751 Views)

Re: How to convert mpolygons to polylines

11-27-2013 06:42 AM in reply to: christer.justusson

command X for explode once to a closed polyline

 

X twice to lines

 

the objects stay on the layer

 

unless you have something different and more information can be given

 

dave

*Expert Elite*
antoniovinci
Posts: 1,668
Registered: ‎06-03-2011
Message 3 of 7 (740 Views)

Re: How to convert mpolygons to polylines

11-27-2013 07:56 AM in reply to: christer.justusson

The _EXPLODE command is a destructive one, so beware of it, sir.

 

Since you're using Autocad Map, you should  _MAPEXPORT the mpolygons to a shapefile, then _MAPIMPORT the latter in a blank drawing (upon checking the flag "Import polygons as closed polylines").

 

Doing so, you get clean 2D polys preserving the original Object Data...

*Expert Elite*
braudpat
Posts: 2,075
Registered: ‎12-15-2006
Message 4 of 7 (723 Views)

Re: How to convert mpolygons to polylines

11-27-2013 12:19 PM in reply to: christer.justusson

 

Hello from France

 

When doing MAPIMPORT (from Surfaces / Closed Polygons) very often we have a very few MPOLYGONS (for example : Parcels/Buildings)

So I import surface object (like Parcels ou Buildings) with the option Creating standard Plines DISABLED !

 

But in fact 99.9 / 99.99% of the objects could be standard closed Plines ...

 

So I have a marvellous/beautiful French VLisp routine (written by a French developper) which analyses MPOLYGONs and if it's MPolygons (without any holes, and NOT multiple) the routine will create a good old closed Pline and then copy ODs (with COPY_OD.lsp routine) from the MPolygons to the created closed Pline !

And if you want the old MPolygons are deleted because now we have a Closed Plines ...

 

Do you want this routine ???

 

It's very very useful !!

 

Bye, Pat

 

 

Bye, Pat

Member
christer.justusson
Posts: 3
Registered: ‎12-13-2010
Message 5 of 7 (702 Views)

Re: How to convert mpolygons to polylines

11-28-2013 05:33 AM in reply to: antoniovinci
Many thanks!
It worked and simple enough for everyone to use. I settled to export to Autodesk SDF for our purpose.
Many many thanks. You solved my problem

H?lsningar Christer Justusson
Member
christer.justusson
Posts: 3
Registered: ‎12-13-2010
Message 6 of 7 (701 Views)

Re: How to convert mpolygons to polylines

11-28-2013 05:41 AM in reply to: braudpat
Hello Pat!
I'm most intrested in trying you LISP routine. Many people here are new to Autocad so I need to make it as simple as possible.
Many thanks in advance.

H?lsningar Christer Justusson
*Expert Elite*
braudpat
Posts: 2,075
Registered: ‎12-15-2006
Message 7 of 7 (689 Views)

Re: How to convert mpolygons to polylines

11-28-2013 09:32 AM in reply to: christer.justusson

 

Hey the MAP/CIVIL MPolygons Fanatics !

 

You will find a ZIP attached ... Thanks to Bruno V. (Bonuscad) for this beautiful routine !

I am using it very often !!

 

With the good old routine COPY_OD which must be preloaded before MP2LW :

So if it's done : the ODs (Object Datas) will be copied from MPolygons to created Plines ... 

 

So you load COPY_OD and then MP2LW and you can run the MP2LW routine ...

There is only one question ... I think you will be able to answer it !?

 

Please let me know if you have any problem !?

 

Bye, Pat

 

Bye, Pat

Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.