Page 2 of 2 FirstFirst 12
Results 11 to 19 of 19

Thread: Getting rid of Ldata

  1. #11
    Member
    Join Date
    2015-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    The LData comes from AtgPro.vlx which was a plot stamp routine we used to use. The routine was encrypted, so it is difficult to figure out exactly how it worked. When I run the remallLdata lisp routine I see that it does indeed remove AtgPro from the data dictionary, but other things are also gone. (I also loaded DictEdit.lsp which shows the data dictionaries in the file.) The ones that are there prior to removing LData but not after are:
    ACAD_ASS0CPERSSUBENTMANAGER (doesn't show anything in that dictionary- if I am interpreting it correctly)
    AcAec (shows AcAecLayerManager as an item in the dictionary)
    GWSUNDORECORDER (no items listed with this one either)

    Update: tested again, this time not letting the remallLdata routine to "hang" as long. Hit escape after about 4 minutes and the only thing gone was the AtgPro.

    I don't get a "not responding", but I am unable to type anything into the command line until I hit escape. An audit shows no errors after that.
    Could a lisp be written to only remove the atgpro?

    Thanks!
    Zoeyanne

  2. #12
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,719
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    Quote Originally Posted by Zoeyanne View Post
    Could a lisp be written to only remove the atgpro?
    This seems to work on my end, just be sure the ATGPRO dictionary's name is spelled correctly:

    Code:
    (vl-load-com)
    
    (defun c:c:DeleteAtgProLData (/ *error* acDoc)
    
      (defun *error* (msg)
        (if acDoc
          (vla-endundomark acDoc)
        )
        (cond ((not msg))                                                   ; Normal exit
              ((member msg '("Function cancelled" "quit / exit abort")))    ; <esc> or (quit)
              ((princ (strcat "\n** Error: " msg " ** ")))                  ; Fatal error, display it
        )
        (princ)
      )
    
      (vla-startundomark
        (setq acDoc (vla-get-activedocument (vlax-get-acad-object)))
      )
      (vlax-for x (vla-get-dictionaries acDoc)
        (if
          (and
            (vlax-property-available-p x 'name)
            (= "AUTOTAGPRO" (strcase (vla-get-name x)))
          )
           (vla-delete x)
        )
      )
    
      (*error* nil)
    )
    Last edited by BlackBox; 2016-01-04 at 09:40 PM. Reason: Code revised
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  3. #13
    Member
    Join Date
    2015-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    AutoTagPro.png
    I get an error message when I load it:
    ; error: malformed string on input

    I ran it anyway, but it did not remove it.
    I did change the lisp to read AutoTagPro as your specified.

    Any ideas?
    Thanks so much!

    Zoeyanne

  4. #14
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,719
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    If you're getting a 'malformed' error, then you've simply copied the code incompletely by mistake, so far as I can tell.
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  5. #15
    Member
    Join Date
    2015-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    You are of course correct! When I copied into notepad I didn't enter after the last line. When I fixed that it does load without error. However, the AutoTagPro dictionary still persists after running the program. What could be preventing it from being removed? Do items in a dictionary have to be removed first?

    Thanks again,
    Zoeyanne

  6. #16
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,719
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    Quote Originally Posted by Zoeyanne View Post
    Do items in a dictionary have to be removed first?
    Perhaps - Can you post a sample drawing?
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  7. #17
    Member
    Join Date
    2015-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    Attached is a drawing with the dreaded LData. Once again I thank you for your time and help!

    Zoeyanne
    Attached Files Attached Files

  8. #18
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,719
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    Thanks for the sample drawing.

    The revised code in this post worked first try, without first needing to delete the Dictionary's sub-elements.

    Cheers
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  9. #19
    Member
    Join Date
    2015-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: Getting rid of Ldata

    A million kudos! Thank you so much!! Worked like a charm!

    Zoeyanne

Page 2 of 2 FirstFirst 12

Similar Threads

  1. Reactors - Persistent, LData, XData...
    By stusic in forum AutoLISP
    Replies: 5
    Last Post: 2013-05-22, 01:42 PM
  2. LDATA errors with AutoCAD 2007
    By Opie in forum AutoLISP
    Replies: 5
    Last Post: 2007-03-30, 10:18 PM
  3. LDATA to XDATA
    By pnorman in forum AutoLISP
    Replies: 3
    Last Post: 2005-06-27, 03:06 PM
  4. Long Term outlook for LDATA
    By jrd.chapman in forum AutoLISP
    Replies: 7
    Last Post: 2005-06-27, 01:54 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
  •