Export coordinates from CAD to txt

Let's assume that we want to export points of CAD format, to a list separated by commas like to load to a total station and make a stake out on site. Previously we had seen how to import them from excel or txt With AutoCAD y With Microstation, Now let's see how to export them.

There are different ways of doing it, such as counting the cows, you can count the legs and divide them by four or you can count the cows nothing more. Let's see some ways:

1 Doing it with Microstation (dgn to txt)

In the example, I have a plot that has five vertices, and I need to export the coordinates to a txt file.

For this, I have put the points in a thickness that are visible. Remember that the thicknesses of line in Microstation are dynamic, so that they are noticed immediately.

Dgn to txt

First step: Activate the coordinate export tool (if it is not active), for this we select

tools
Tool boxes
We activate the last command (xyz)
Then we closed the panel and should have been activated this way

Xyz dgn

Second step: Select the points that we want to export, then select the command "export coordinates", which is the arrow up and fill the conditions:Export coordinates

-Data file
-File name
-Order of coordinates
- Primary units
-Decimals
-Separator
-View
-Prefix / suffix
- Initial number

The panel allows you to choose the options, if only the selected drawings (single), the drawings inside a fence or all the file (all)

The end result is a .txt file that you can open from excel.

In my case I have assigned number, marking the checkbox that is on the right

In case the file already exists a window that asks if you want to replace or add (add or append) is displayed.

Txt coordinatesTo identify which are the points, microstation draws you numbers in each point, with the color, type of line and size of text that you have active.

2 Doing it with AutoCAD

Before knowing CivilCAD (Softdesk) we used a DOS application that is still there called Dxf2csv. You can try it if you like to torture yourself with nostalgia, 🙂 there are also some applications «not free«, And I am sure that there should be some free but in this case we will see how it is done with Softdesk8, it is similar in CivilCAD.

In order to make the points visible, I have changed the format with format / format point / point style. So that for the thickness of the lines to be visible you have to activate «Lts», using a lower value of 1 until we see the difference.

Dwg to txt

First step: Open a project or create a new project

AEC
Softdesk programs (save file first time)
Create project
Assign project name, then ok
We choose the number where the numbering begins
Ok ok, ok then
we choose «cogo», then ok

Second step: Enter the points to the database: for this, there are different forms, in this case we will do it automatically: Points / set points / automatic, then select each line of the polygon.
The signal that was entered is to make points / set points / list avaible points. It should show + 6, which means that there are already 5 points entered into the database.

Third step: Export the points.
To export the points we do:

-points / import-export points / export points to file
- Select the export format, in this case PNE (point, northing, easting)
-We choose the destination folder of the file and write the name
- In the command bar we choose the export options (by selection, by rank ... in this case we use all, all)
-List, the file has gone, in this case separated by expacios but equal can be opened with excel

Autocad txt

In case the points are written in too large sizes, you have to change the metric units because by default come the English (AEC / setup drawing / unit angles / choose métric)

This time the points did not have elevation, that subject we will see in another post, when we speak of curves of level.

Tolerate my insistence, does anyone know a macro for atocad that is simpler and free?

Does anyone else do it?

18 Replies to "Export CAD coordinates to txt"

  1. For that, you need CivilCAD or Civil3D. Both are specialized modules that work on AutoCAD.
    AutoCAD alone does not allow you to do that.

  2. apologize for my initiation, I need to know how to pass and / or draw cuts or section in autocad directly with reading height and distances (track width) each 20 mt. longitudinal and at the same time I go calculating the volume of fillings and excavations directly in autocad

  3. well this post is excellent there are many support tools to simplify the work and it would also be good to rely on civilcad that is very practical to use, but the important thing is to know the origin of each concept

  4. Hello Kovos in this post We explain how to do it with Softdesk8. I tell you that we cannot through this blog recommend ways to acquire pirated software, in this post I mentioned that Vuze It works for that, but it's at your risk.

  5. How do I draw the level curves in Aautocad? How do I download the softdesk8?

  6. Hello Jorge Luis

    First, in the total station, it exports the points to .txt format, preferably in order: x coordinate, y coordinate, elevation, description.

    Then open them with Excel, choosing the file of type .txt

    Choose the option delimited by commas, so you can separate the columns

    To have them in excel I recommend that you use this tool, Which exports excel to dxf

  7. I need the steps to apoder export the points of the station to Excel ... Thanks

    Urgent

  8. I would appreciate it, please. It is for my thesis and I only have to do this to advance and culminate. THANK YOU.

  9. Daniel, let me find a vba I used some time ago and upload it for you to try

    Give me this day

  10. No, that only serves you to import points.
    I'll get a vba and I'll upload it for you to try.

  11. WHAT DO I DO TO IMPORT THE COORDINATES FROM EXCEL TO MICROSTATION AND THAT I DIGUTE THE LINES; THROUGH THE TOOL BOXER APPLICATION> XYZtext> IMPORT COORDINALES ???????

    IS IT SAY HOW I USE THIS APPLICATION TO IMPORT ???

  12. GOOD DAY, GALVAREZHN

    Thanks, but my case is this:

    I have a database in Excel where I have the source coordinates and destination coordinates, and I want to draw the lines in autocad. «» »BUT» »» Without copying and pasting, but the operation is automatic, that is, with a macro or some code to create the interface, or perhaps within AUTOCAD or MICROSTATION EXISTS THAT INTERFACE that imports the data from excel AUTOCAD or MICROSTATION if it is the case

    what do you suggest galvarezhn
    ??????????? THANK YOU

  13. I am a THESISIST and I am looking for how I can automatically draw lines in AutoCAD from a database in Excel, that is, having the coordinates ORIGIN and coordinates DESTINATIONS

    BUT I DONT DRAW POINTS BUT LINES DIRECTLY IS SAYING POINT ORIGIN AND VARIOUS POINTS DESTINATIONS
    THANK YOU

  14. This lisp can do it

    (Defun c: txt-xyzs ()
    (Setq a (ssget)
    N (sslength a)
    the 0
    f (open (getstring «\ nfilename:«) «w»)
    )
    (Repeat n
    (Setq name (ssname ai)
    Ent (entget name)
    Tp (cdr (assoc 0 ent))
    )

    (if (= «TEXT» tp)
    (If (and (= (cdr (assoc 71 ent)) 0) (= (cdr (assoc 72 ent)) 0))
    Progn
    (Setq ip (cdr (assoc 10 ent))
    X (rtos (car ip) 2 2)
    And (rtos (cadr ip) 2 2)
    Z (rtos (caddr ip) 2 2)
    S (cdr (assoc 1 ent))
    )
    (princ (strcat x «,» y «,» z «,» s «\ n») f)
    ); Left-justified text
    Progn
    (Setq ip (cdr (assoc 11 ent))
    X (rtos (car ip) 2 2)
    And (rtos (cadr ip) 2 2)
    Z (rtos (caddr ip) 2 2)
    S (cdr (assoc 1 ent))
    )
    (princ (strcat x «,» y «,» z «,» s «\ n») f)
    ); Other than left-justified
    ); If
    ); If

    (if (= «MTEXT» tp)
    Progn
    (Setq ip (cdr (assoc 10 ent))
    X (rtos (car ip) 2 2)
    And (rtos (cadr ip) 2 2)
    Z (rtos (caddr ip) 2 2)
    S (cdr (assoc 1 ent))
    )
    (princ (strcat x «,» y «,» z «,» s «\ n») f)
    ); Left-justified text
    ); If mtext

    (Setq i (1 + i))
    ); Repeat
    (Close f)
    )

Leave an answer

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.