Results 1 to 6 of 6

Thread: Import Table made in AutoCAD 2000 to Excel with same column and rows

  1. #1
    Active Member
    Join Date
    2006-05
    Location
    Pind
    Posts
    63

    Question Import Table made in AutoCAD 2000 to Excel with same column and rows

    How can i import Table made in autocad2000 to excel with same column and rows.
    thanks

  2. #2
    Member
    Join Date
    2007-03
    Posts
    16

    Default Re: Import Table made in AutoCAD 2000 to Excel with same column and rows

    How is your table set up in AutoCAD 2000? Is it an MTEXT, individual TEXTs, or what?

    As an MTEXT, your solution is simple: just export it to a file using DDEDIT, then read that file into Excel as a space-delimited file.

    For individual TEXT entities, here's a code snippet that will allow you to write a column of a chart at a time out to a file:
    Code:
    ;usage: (WriteColumn "C:\\SomeFolder\\OutputFileName.txt")
    (defun WriteColumn ( strFileSpec / pt ss entText lstTexts filHandle lstOut )
      (if (not  strFileSpec) (setq strFileSpec ""))	;quick-n-dirty error trap--prevents error during *error* function
      (setq pt (getpoint "\nIndicate top, left of column: "))
      (setq ss (ssget '((0 . "TEXT"))))		;select only text entities
      ;compose of list of just the text values associated with their distances from the top, left of the column
      (while (> (sslength ss) 0)
        (progn
          (setq entText (entget (ssname ss 0)))
          (setq lstTexts (append lstTexts (list (cons (distance pt (cdr (assoc 10 entText)))
    						  (cdr (assoc 1 entText))
    				            )
    				      )
    		     )
          )
          (ssdel (ssname ss 0) ss)
        )
      )
      ;sort the list into order by increasing distances ("top-to-bottom")
      (setq lstTexts (vl-sort lstTexts '(lambda (t1 t2) (< (car t1) (car t2)))))
      ;write the output
      (setq filHandle (open strFileSpec "w"))
      (if filHandle
        (foreach lstOut lstTexts (write-line (cadr lstOut) filHandle))
        (*error* (strcat "Unable to open " strFileSpec " for writing output."))
      )
      (close filHandle)
    )
    Last edited by shawn.bean; 2007-04-02 at 07:36 PM.

  3. #3

    Default Re: Import Table made in AutoCAD 2000 to Excel with same column and rows

    Hello,

    I'm not used with lisp function so I need help. I don;t know how should I use the function wrote before: I've copy it to a lisp file and I've loaded in autocad drawing but nothing it is going on. What should I do ?
    Thank You

  4. #4
    AUGI Addict fixo's Avatar
    Join Date
    2005-05
    Location
    Pietari, Venäjä
    Posts
    1,211

    Default Re: Import Table made in AutoCAD 2000 to Excel with same column and rows

    Quote Originally Posted by ala.balaportocala256381 View Post
    Hello,

    I'm not used with lisp function so I need help. I don;t know how should I use the function wrote before: I've copy it to a lisp file and I've loaded in autocad drawing but nothing it is going on. What should I do ?
    Thank You
    Take a look at this article
    http://lee-mac.com/runlisp.html

    You might be want to try another lisp as well

    ~'J'~
    Attached Files Attached Files
    "The whole problem with the world is that fools and fanatics are always
    so certain of themselves, and wiser people so full of doubts."
    Bertrand Russell

  5. #5

    Default Re: Import Table made in AutoCAD 2000 to Excel with same column and rows

    Thank You very much.
    Do You know any place - website, book, where there are lessons for begginers for learning lisp ?
    I've some information on the http://lee-mac.com/
    Last edited by ala.balaportocala256381; 2011-03-31 at 06:10 PM.

  6. #6
    AUGI Addict fixo's Avatar
    Join Date
    2005-05
    Location
    Pietari, Venäjä
    Posts
    1,211

    Default Re: Import Table made in AutoCAD 2000 to Excel with same column and rows

    Quote Originally Posted by ala.balaportocala256381 View Post
    Thank You very much.
    Do You know any place - website, book, where there are lessons for begginers for learning lisp ?
    I've some information on the http://lee-mac.com/
    See my response here
    http://forums.augi.com/showpost.php?...18&postcount=5
    "The whole problem with the world is that fools and fanatics are always
    so certain of themselves, and wiser people so full of doubts."
    Bertrand Russell

Similar Threads

  1. Replies: 9
    Last Post: 2010-05-03, 09:19 PM
  2. Excel Table to AutoCAD Table.
    By Spenner in forum AutoCAD Tables
    Replies: 19
    Last Post: 2009-05-20, 03:04 PM
  3. How to import excel table to autocad
    By mandy in forum AutoCAD General
    Replies: 5
    Last Post: 2008-10-31, 06:32 PM
  4. AutoCAD LT 2000 lineweights not showing in Excel
    By swaims in forum AutoCAD LT - General
    Replies: 1
    Last Post: 2007-06-20, 07:23 PM
  5. Import jpeg & tiff into AutoCAD LT 2000
    By simons72 in forum AutoCAD LT - General
    Replies: 3
    Last Post: 2006-02-14, 10:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •