Urgent: Converting AutoCAD DWG to Shapefile whilst keeping annotations

13595
5
09-16-2011 07:59 PM
DanielBrown3
New Contributor
Hi everyone,

I'm currently in Haiti helping with some cadastral mapping and only have 10 dyas left to get everything done here. For this particular project, I've been given building polygons from AutoCAD in DWG format. Each polygon has been annotated with the owner's name, number of storeys, enumeration number and building size. When I try to convert the DWG to a Shapefile though these attributes are being lost. I don't think the annotations have been 'locked' to the polygons. Is there any way around this at all? I'd be really grateful if somebody could tell me if there was a solution that allowed these annotations to be imported into ArcGIS, as it will save me some time having to manually input them again.

I've uploaded the DWG here: http://dl.dropbox.com/u/19551996/The%20New%20DWG%20%28Georeferenced%29%281%29.zip

All the best,
Daniel
Tags (2)
5 Replies
MatthewDillon
New Contributor
This is something that I have tinkered with as a quick alternative for creating data for ArcGIS within AutoCad. Here's the best way I found to do it:

1. Add the DWG to ArcMap, and then expand the .dwg Group Layer. Right click on the .dwg Polygon layer under this, and click on Export Data to export a polygon feature class out. For this to work, the polylines in the drawing need to be clean and closed. Any that aren't will not be exported to polygons.

2. Under the .dwg Group Layer again, right click on your .dwg Annotation layer and open up its Properties. In the Properties window, go to the Drawing Layers tab. Make it so that only one of your annotation layers is on.

3. Right click on the polygon created in step 1, and go to Joins and Relates and then to Join... In the first drop-down, click that you want to Join data from another layer based on spatial location. In step 1, choose the .dwg Annotation layer as the layer you'd like to join  to this. In step 2, click the second option (Each polygon will be given the attributes of the polygon it falls completely inside of, etc...). Lastly, specify the location of your new feature class and export it out. When you open this feature class' attribute table, you should see that in one of the columns, your annotation has been associated with the polygon in which it exist.

4. Go back to your .dwg Annotation layer and turn off the layer you just made into an attribute and turn on the next one to use. Repeat the above steps, joining the Annotation to the second feature class you made (with the first set of annotation). I haven't figured out how to have annotation from different layers get put into different columns when doing the spatial join unless each annotation layer is turned on separately and joined individually. In your case, you'll have to do four different spatial joins for the four attributes you described in your .dwg.

5. Go through your new polygon feature class, which has the annotation as attributes in it; and delete the fields you don't need. There will be many new fields added that have to do with the .dwg format, etc. You may also need to create new fields that are an appropriate type to handle the annotation properly (numbers in a numeric type, text in a text type, etc) and then populate these with the field calculator.

Please let me know if I need to clarify anything. I'll be curious to see if anyone else has a better method to do this too.
Sakkeerhussain
New Contributor
Hi,
Itried the above method but failed due to the error attached. I also have tried to project the CAD annotation but failed.
Hope you will reply to this .
Thanks
sakkeer
0 Kudos
SandyHannum
New Contributor
I just wanted you to know that you saved me tons of time. I needed to exactly this on a DWG with over 3,000 polygons, and all I needed from the annotation layer was one simple column of information that would allow me to join the data to several different excel spreadsheets. Thank you very much.

Please let me know if I need to clarify anything. I'll be curious to see if anyone else has a better method to do this too.
0 Kudos
samjohn
New Contributor
Hi everyone,

I'm currently in Haiti helping with some cadastral mapping and only have 10 dyas left to get everything done here. For this particular project, I've been given building polygons from AutoCAD in DWG format. Each polygon hs been annotated with the owner's name, number of storeys, enumeration number and building size. When I try to convert the DWG to a Shapefile though these attributes are being lost. I don't think the annotations have been 'locked' to the polygons. Is there any way around this at all? I'd be really grateful if somebody could tell me if there was a solution that allowed these annotations to be imported into ArcGIS, as it will save me some time having to manually input them again.

I've uploaded the DWG here: http://dl.dropbox.com/u/19551996/The%20New%20DWG%20%28Georeferenced%29%281%29.zip

All the best,
Daniel



What version of ArGIS are you using, cos am working on your project now
0 Kudos
ColmO_Kane
New Contributor II
This is something that I have tinkered with as a quick alternative for creating data for ArcGIS within AutoCad. Here's the best way I found to do it:

1. Add the DWG to ArcMap, and then expand the .dwg Group Layer. Right click on the .dwg Polygon layer under this, and click on Export Data to export a polygon feature class out. For this to work, the polylines in the drawing need to be clean and closed. Any that aren't will not be exported to polygons.

2. Under the .dwg Group Layer again, right click on your .dwg Annotation layer and open up its Properties. In the Properties window, go to the Drawing Layers tab. Make it so that only one of your annotation layers is on.

3. Right click on the polygon created in step 1, and go to Joins and Relates and then to Join... In the first drop-down, click that you want to Join data from another layer based on spatial location. In step 1, choose the .dwg Annotation layer as the layer you'd like to join  to this. In step 2, click the second option (Each polygon will be given the attributes of the polygon it falls completely inside of, etc...). Lastly, specify the location of your new feature class and export it out. When you open this feature class' attribute table, you should see that in one of the columns, your annotation has been associated with the polygon in which it exist.

4. Go back to your .dwg Annotation layer and turn off the layer you just made into an attribute and turn on the next one to use. Repeat the above steps, joining the Annotation to the second feature class you made (with the first set of annotation). I haven't figured out how to have annotation from different layers get put into different columns when doing the spatial join unless each annotation layer is turned on separately and joined individually. In your case, you'll have to do four different spatial joins for the four attributes you described in your .dwg.

5. Go through your new polygon feature class, which has the annotation as attributes in it; and delete the fields you don't need. There will be many new fields added that have to do with the .dwg format, etc. You may also need to create new fields that are an appropriate type to handle the annotation properly (numbers in a numeric type, text in a text type, etc) and then populate these with the field calculator.

Please let me know if I need to clarify anything. I'll be curious to see if anyone else has a better method to do this too.


excellent solution, you just saved me a lot of time and hassle as all annoations are in one layer so it was really quic to complete! Thank you.
0 Kudos