Jump to content

excel to autocad


Guest nodavilp

Recommended Posts

If the coordinates are in some logical order in Excel then you can draw something (e.g. lines, polylines, or points) by using a script, or by pasting the coordinates into AutoCAD's command line after starting a command. As an example, if you have coordinates with x&y values in separate colums, in another column write a formula to combine them in the format "x,y". To connect thes coordinates with a polyline, start ye polyline command, and when prompted for a point copy the entire column of "x,y" values, then paste into AutoCAD, and the PL will be drawn through the points.

Link to comment
Share on other sites

  • 10 months later...
  • 4 years later...

Then do a second script to draw those labels:

_TEXT _J [color=black]_M _non[/color] [i][color=blue]X,Y,Z[/color][/i] 5.0 0.0 [i][color=blue]X,Y,Z[/color][/i]

There should be one line for each label; adjust the alignment (currently Middle) and height (currently 5.0) for your needs.

Link to comment
Share on other sites

Use the features of Excel (or a spreadsheet tool of your choice) to edit the points into a script to draw the polyline and also add the labels. Check on the help of that tool for formulas to build strings (concatenation).

Your script should look something like:

_PLINE 110.0,120.0 210.0,220.0 310.0,330.0 
_TEXT _J _M 110.0,120.0 5.0 0.0 "110.0, 120.0"
_TEXT _J _M 210.0,220.0 5.0 0.0 "210.0, 220.0"
_TEXT _J _M 310.0,320.0 5.0 0.0 "310.0, 320.0"
_ZOOM _E

Just don't forget to save it as an ASCII file (simple text) - for more information check the tutorial recommended above. You cannot run it directly from Excel, should use the SCRIPT command inside AutoCAD.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...