Community
Civil 3D Forum
Welcome to Autodesk’s Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Convert blocks to points

21 REPLIES 21
SOLVED
Reply
Message 1 of 22
JasperBoekling
34628 Views, 21 Replies

Convert blocks to points

Hi guys,

 

 

I want to convert blocks to points so I can make point groups from all blocks I have. I know I can use EATTEXT to extract the xyz from the blocks and import them into C3D as points. But is there a way to directly create points from block without having to export and import them?

 

By the way, I can export the rotation of the block but I can't import the rotation when creating points.

 

Thanks in advance!

21 REPLIES 21
Message 2 of 22
Jeff_M
in reply to: JasperBoekling

What kind of blocks do you have? Are they old Softdesk Point blocks? Eagle Point blocks? Just random blocks at elevation? Can you post a small dwg file with a few of these blocks in it?

Jeff_M, also a frequent Swamper
EESignature
Message 3 of 22
JasperBoekling
in reply to: Jeff_M


@Jeff_M wrote:

What kind of blocks do you have? Are they old Softdesk Point blocks? Eagle Point blocks? Just random blocks at elevation? Can you post a small dwg file with a few of these blocks in it?


Hi Jeff, thank you so far,

 

They are Block References, i dont know what Softdesk Point Blocks or Eagle Point Blocks are? I suppose they are random blocks at evevation.

 

block reference.PNG

 

I have also attached a .dwg with a few blocks in it.

Message 4 of 22
Jeff_M
in reply to: JasperBoekling

OK, thanks for the dwg. Yes, they are just plain blocks, without attributes. Most are at 0 elevation. A custom macro (lisp or .NET app) could probably be written to do this. I would think that for each block type a PointStyle would need to be either found to exist, or created on the fly, to display the same block as is currently there. Unfortunately, I don't have time right now to write such an app. Hopefully someone else may be able to help with that. If this is still something needed in a few months when my time frees up, I would be happy to help out then.
Jeff_M, also a frequent Swamper
EESignature
Message 5 of 22

Your inserts don't contain any additional information such as attributes, so you can use the AutoCAD built in Extraction tools to create an ascii file.

 

Attached is an AUF file of the coordinates.

Message 6 of 22
JasperBoekling
in reply to: Jeff_M


@Jeff_M wrote:
OK, thanks for the dwg. Yes, they are just plain blocks, without attributes. Most are at 0 elevation. A custom macro (lisp or .NET app) could probably be written to do this. I would think that for each block type a PointStyle would need to be either found to exist, or created on the fly, to display the same block as is currently there. Unfortunately, I don't have time right now to write such an app. Hopefully someone else may be able to help with that. If this is still something needed in a few months when my time frees up, I would be happy to help out then.

Thank you Jeff, I also have some blocks elsewhere in my drawing which do contain elevation and rotation. The Point Styles are no problem, I know how to fix those, already have some ready to use; a colleague of mine has some styles. 

 

Thanks for your help! 🙂

 


@TerryDotson wrote:

Your inserts don't contain any additional information such as attributes, so you can use the AutoCAD built in Extraction tools to create an ascii file.

 

Attached is an AUF file of the coordinates.


 You mean by using EATTEXT, right? I indeed know that way, I was hoping there was a way to create points on the spot without having to create an ascii file..

Message 7 of 22

Hi Jeppert,
I made a sample LISP Macro for this case 10 Years ago, but it is still usably and exactly what you are asking for.
Unfortunately the comments and prompts in this macro are in german. If this doesen't bother you, you can download an test it.
http://www.cad-huebner.de/download/UHBLock2Civilpoint.LSP
If you need an english translated Version it will take a coupl of days.
Udo Huebner

 

Message 8 of 22

Start by copying the drawing or the blocks because they will be replaced. Set one random Cogo Point as a template. Use the Create Blocks from Cogo Points command to create the block named Point.

 

btp1.png

 

Then use the Blockreplace command from Express Tools to replace your blocks with the block name Point. Finally use the Replace Softdesk Point Blocks command from the bottom above. That will yield Cogo Points. 

Allen Jessup
CAD Manager - Designer
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

Message 9 of 22


@Udo_Huebner2 wrote:

Hi Jeppert,
I made a sample LISP Macro for this case 10 Years ago, but it is still usably and exactly what you are asking for.
Unfortunately the comments and prompts in this macro are in german. If this doesen't bother you, you can download an test it.
http://www.cad-huebner.de/download/UHBLock2Civilpoint.LSP
If you need an english translated Version it will take a coupl of days.
Udo Huebner

 


Wow this does exacly what i wanted it to do.

 


@AllenJessup wrote:

Start by copying the drawing or the blocks because they will be replaced. Set one random Cogo Point as a template. Use the Create Blocks from Cogo Points command to create the block named Point.

 

btp1.png

 

Then use the Blockreplace command from Express Tools to replace your blocks with the block name Point. Finally use the Replace Softdesk Point Blocks command from the bottom above. That will yield Cogo Points. 


This also does what I want, but the solution of Udo is faster, thanks!

 

 

 

Quick extra question, is there a way that I can also transfer the rotation of my block to the point? I want to export the points to Infraworks with an SDF so i can map them to objects, it would be awesome if it is also possible to get the rotation from the blocks.

Message 10 of 22

You're welcome. I knew the Lisp would be faster if it worked for you. But I'd just thought up the method I posted. So I wanted to share it in case the lisp didn't work. Thanks.

Allen Jessup
CAD Manager - Designer
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

Message 11 of 22

Hi @JasperBoekling, in some cases the AutoCAD block consists of a symbol and an annotation for the elevation. Then you could also use the MoveTextToElevation command. The workflow is demonstrated in this blog post: http://civilimmersion.typepad.com/civil_immersion/2017/06/tool-for-tuesday-movetexttoelevation.html Regards, Karsten


Karsten Saenger
Message 12 of 22
Anonymous
in reply to: udo.huebner

Did you ever post the translation?

Message 13 of 22
Anonymous
in reply to: JasperBoekling

Thanks for posting this problem. I found it helpful. However, both of the methods posted here could not show the point description. The CAD tool converted all blocks, but messed up with the point number. The lisp could keep the point number, but still didn't show description. I have translated the comments to English, but couldn't figure out how to add description. I'm not familiar with the lisp programming. If anyone is good at it, could you please help? 

The attached is the English version of the lisp and a test file with blocks of points.

Thanks,

Yangbin

 

Message 14 of 22
Anonymous
in reply to: Anonymous


@Anonymous wrote:

Did you ever post the translation?


I have translated it and added a couple of lines in the code so that Point Number and Descriptions will also show correctly. Please see attached. 

 

@udo.huebner

Thank you for posting the original code. It helped me. 

Message 15 of 22
Anonymous
in reply to: Anonymous

Awesome thank you

Message 16 of 22
vancouverisgreat
in reply to: Anonymous

Hi 🙂 is it possible to select multiple blocks and convert to COGO altogether with this LISP?

Message 17 of 22
Anonymous
in reply to: vancouverisgreat

Yes. The original author wrote the code to convert all selected blocks to COGO points.

 

If you came across with any problem, you can refer the following post. 

https://forums.autodesk.com/t5/civil-3d-forum/error-bad-argument-type-vla-object-nil/m-p/8434933#M38...

 

Good luck!

 

Message 18 of 22
Anonymous
in reply to: Anonymous

Is a very interesting article Give new knowledge as well. Thank you very much
 [คาสิโนออนไลน์](https://ufa007.co/casino)
:R
Message 19 of 22
Anonymous
in reply to: JasperBoekling

1. Create tin surface and add blocks
2. Make points visible in surface style
3. Extract from Surface --> extract points
4. Convert AutoCAD points

Message 20 of 22
tom4YHX5
in reply to: JasperBoekling

Thanks for the lisp to convert block to cogo points, but is there a way to change this to allow to hold the existing information that is within the block. I have a file given to me that was created with the points I need are a block and I need the block to be convert and retain the same point number, the elevation value and the description. Also for some reason the when I run the lisp routine it places 2 points for every block, please see attached file.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report