hosyn Posted May 21, 2013 Posted May 21, 2013 i have some dwg file from some consulating co and they have unic Id located in th drawing --if i wana search them i need searching for that id..... I need a lisp for export selected text in drawing and merge with the name of that dwg file at the same file or separated txt filename at that folder....any suggestion lisp.. Quote
ReMark Posted May 21, 2013 Posted May 21, 2013 Take a look at the data extraction command EATTEXT. Maybe it will be of some use to you. Quote
cadvision Posted May 22, 2013 Posted May 22, 2013 is this still on your educational copy? Suggest if you doing commercial work then at least switch to nanoCAD and be legit Quote
ReMark Posted May 22, 2013 Posted May 22, 2013 What command in nanoCAD would he be advised to use? Quote
hosyn Posted May 30, 2013 Author Posted May 30, 2013 I need a lisp for export selected text in drawing and merge with the name i have some dwg file from some consulating co and they have unic Id located in th drawing --if i wana search them i need searching for that id..... I need a lisp for export selected text in drawing and merge with the name of that dwg file at the same file or separated txt filename at that folder....any suggestion lisp.. Quote
neophoible Posted May 31, 2013 Posted May 31, 2013 I need a lisp for export selected text in drawing and merge with the name i have some dwg file from some consulating co and they have unic Id located in th drawing --if i wana search them i need searching for that id..... I need a lisp for export selected text in drawing and merge with the name of that dwg file at the same file or separated txt filename at that folder....any suggestion lisp.. Instead of just repeating yourself, how about showing what you want to do via some posted pics with explanations. Are you sure it is TEXT? Is that what it says when you LIST it? Quote
hmsilva Posted May 31, 2013 Posted May 31, 2013 If I understand correctly, perhaps something like this: (defun c:test (/ Ofil s TxtFile tx txt) (prompt "\nSelect text with the Id: ") (if (and (setq s (ssget ":S" '((0 . "TEXT")))) (setq TxtFile (strcat (getvar "dwgprefix") "YourFileName.txt")) );; and (progn (setq tx (cdr (assoc 1 (entget (ssname s 0)))) txt (strcat tx " - " (getvar "dwgname")) Ofil (open TxtFile "a") ) (write-line txt Ofil) (close Ofil) );; progn );; if );; test Henrique Quote
Recommended Posts
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.