Search the Community
Showing results for tags '.csv'.
Hi guys, There are a number of forum topics around the internet asking similar questions, each with good answers (e.g. Lee Mac here) but so far I haven't found an answer to my problem. What I would like to do is extract information from several long polylines (each on specific layers) and create a csv text file of the output, saved to the same directory and with the same name as the .dwg file. I need each row of the .csv file to contain the coordinates of one point on a polyline (X,Y,Z) but then additionally include a fourth 'label' column which would be in the format: [DrawingName]_[Layer] DrawingName = name of the .dwg file Layer = layer the polyline is on Example output: X,Y,Z,Dwg1_layer1 X,Y,Z,Dwg1_layer1 ;one row for each point on polyline X,Y,Z,Dwg1_layer1 .... X,Y,Z,Dwg1_layer2 ;this is the next polyline, on 'layer2' X,Y,Z,Dwg1_layer2 X,Y,Z,Dwg1_layer2 etc The label column is necessary as I need to combine information from many different files and the ability to identify and sort where the data came from is essential. I've attempted to modify existing 'extract XYZ' code that I've found around the internet but it seems to be beyond my current lisp skills . Any help you guys can give would be simply amazing!