Author Topic: Duplicate Points - Different Point number (Land)  (Read 6056 times)

0 Members and 1 Guest are viewing this topic.

dfarris75

  • Guest
Duplicate Points - Different Point number (Land)
« on: November 11, 2008, 03:41:12 PM »
In Land Desktop how would one quickly remove duplicate points that have different point numbers, but same coords, desc, and z?

Jeff_M

  • King Gator
  • Posts: 4100
  • C3D user & customizer
Re: Duplicate Points - Different Point number (Land)
« Reply #1 on: November 11, 2008, 04:34:28 PM »
Here's what Terry Dotson of Dotsoft.com posted to the Autodesk newsgroup last year:
Quote from: Terry Dotson

Here's one approach.

Terry
Code: [Select]
; ------------------------------------------------------
;     (Delete duplicate AECC points from drawing)
;  (Duplicate defined as having same XYZ coordinates)
;    Copyright (C) 2000 DotSoft, All Rights Reserved
;           Website: http://www.dotsoft.com
; ------------------------------------------------------

(defun C:AECPTDUP2 ()
   (setq llc (getpoint "\nDS> Pick LL Corner: "))
   (setq urc (getcorner llc "\nDS> Pick UR Corner: "))
   (setq dsx (- (car urc)(car llc)))
   (setq dsy (- (cadr urc)(cadr llc)))
   (setq ndx (+ (fix (/ dsx 100.0)) 1))
   (setq ndy (+ (fix (/ dsy 100.0)) 1))
   (setq tmp (getint (strcat "\nDS> X Divisions <" (itoa ndx) ">: ")))
   (if (/= tmp nil)(setq ndx tmp))
   (setq tmp (getint (strcat "\nDS> Y Divisions <" (itoa ndy) ">: ")))
   (if (/= tmp nil)(setq ndy tmp))
   (setq tmp (getdist "\nDS> Fuzz Factor <0.00000001>: "))
   (if (/= tmp nil)(setq fuzz tmp)(setq fuzz 0.00000001))
   (setq incx (/ dsx ndx))
   (setq incy (/ dsy ndy))
   ;
   (setq cmdecho (getvar "CMDECHO"))
   (setvar "CMDECHO" 0)
   (command "_.UNDO" "_G")
   (setq cel 0)
   (setq tot (* ndx ndy))
   (setq llx (car llc))
   (setq lly (cadr llc))
   (princ "\nDS>")
   (repeat ndx
     (setq urx (+ llx incx))
     (repeat ndy
       (setq cel (1+ cel))
       (princ (strcat "\rDS> Processing Cell " (itoa cel)
                      " of " (itoa tot)))
       (setq ury (+ lly incy))
       (setq sset (ssget "_C" (list llx lly) (list urx ury)
                          '((0 . "AECC_POINT"))))
       (if sset
         (progn
           (setq lst nil)
           (setq num (sslength sset) itm 0)
           (while (< itm num)
             (setq hnd (ssname sset itm))
             (setq ent (entget hnd))
             (setq xyz (cdr (assoc 11 ent)))
             (setq ptn (cdr (assoc 90 ent)))
             (setq rec (list ptn xyz hnd))
             (setq lst (append lst (list rec)))
             (setq itm (1+ itm))
           )
           (setq sset nil)
           ;
           (if (> (length lst) 1)
             (progn
               (foreach rec lst
                 (if (/= rec nil)
                   (progn
                     (setq ptn (car rec))
                     (setq xyz (cadr rec))
                     (setq hnd (caddr rec))
                     (foreach crec lst
                       (if (/= rec nil)
                         (if (/= crec nil)
                           (progn
                             (setq cptn (car crec))
                             (setq cxyz (cadr crec))
                             (setq chnd (caddr crec))
                             (if (equal cxyz xyz fuzz)
                               (cond
                                 ((> cptn ptn)
                                   (setq lst (subst nil crec lst))
                                   (entdel chnd)
                                 )
                                 ((< cptn ptn)
                                   (setq lst (subst nil rec lst))
                                   (setq rec nil)
                                   (entdel hnd)
                                 )
                                 (t nil)
                               )
                             )
                           )
                         )
                       )
                     )
                   )
                 )
               )
             )
           )
         )
       )
       (setq lst nil)

       (setq lly (+ lly incy))
     )
     (setq llx (+ llx incx))
     (setq lly (cadr llc))
   )
   (princ ", Done.")
   (command "_.UNDO" "_E")
   (setvar "CMDECHO" cmdecho)
   (princ)
)

(princ "\nDS> AECPTDUP2.LSP Loaded ... type AECPTDUP2 to run.")
(princ)

Jeff_M

  • King Gator
  • Posts: 4100
  • C3D user & customizer
Re: Duplicate Points - Different Point number (Land)
« Reply #2 on: November 11, 2008, 04:40:09 PM »
Also, there are the ideas presented HERE

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #3 on: November 11, 2008, 04:51:18 PM »
In Land Desktop how would one quickly remove duplicate points that have different point numbers, but same coords, desc, and z?

IF one is using Land desktop,
Then one should use MAP>>Tools>>Drawing Cleanup>>And select delete duplicates....
Be your Best


Michael Farrell
http://primeservicesglobal.com/

Jeff_M

  • King Gator
  • Posts: 4100
  • C3D user & customizer
Re: Duplicate Points - Different Point number (Land)
« Reply #4 on: November 11, 2008, 05:05:31 PM »
Michael, I've seen this mentioned by you before but I could never get it to work. I just tried again and the Point objects are not even allowed to be selected for cleanup. Could you elaborate on how this is done? Thanks, Jeff.

dfarris75

  • Guest
Re: Duplicate Points - Different Point number (Land)
« Reply #5 on: November 12, 2008, 08:56:34 AM »
Thanks guys.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #6 on: November 12, 2008, 10:41:21 AM »
Michael, I've seen this mentioned by you before but I could never get it to work. I just tried again and the Point objects are not even allowed to be selected for cleanup. Could you elaborate on how this is done? Thanks, Jeff.

If you are using Land desktop they CAN be selected.

If you are using C3D NOTHING (C3D objects) that you create can interact with MAP.
Are you trying this with C3D?
This is why I have been howling like crazy for 5 years now over the lack of MAP functionality with C3D objects.
Perhaps now I don't appear to be as crazy as some think..... ;-)
Be your Best


Michael Farrell
http://primeservicesglobal.com/

Jeff_M

  • King Gator
  • Posts: 4100
  • C3D user & customizer
Re: Duplicate Points - Different Point number (Land)
« Reply #7 on: November 12, 2008, 11:37:25 AM »
No, not C3D. I tried this in LDT Companion 2008. I just tried again using LDT3, same results......selecting 376 LDT points shows as "No Objects selected" in the Drawing Cleanup dialog.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #8 on: November 12, 2008, 11:53:09 AM »
No, not C3D. I tried this in LDT Companion 2008. I just tried again using LDT3, same results......selecting 376 LDT points shows as "No Objects selected" in the Drawing Cleanup dialog.

Were those points created in Land?

Or, did they (autodesk) finally break it (MAP) inside Land Desktop as well?
Be your Best


Michael Farrell
http://primeservicesglobal.com/

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #9 on: November 12, 2008, 12:21:19 PM »
Wow,  I just found an old version of Land (2004) and imported some points and sure enough drawing cleanup does NOT work with point objects.  It's been broken for longer than I've known.  :|
Be your Best


Michael Farrell
http://primeservicesglobal.com/

sinc

  • Guest
Re: Duplicate Points - Different Point number (Land)
« Reply #10 on: November 12, 2008, 12:30:02 PM »
OK, who has R14 Map to test it out?  Or did Map even exist for R14?

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #11 on: November 12, 2008, 12:36:31 PM »
uh no....
Be your Best


Michael Farrell
http://primeservicesglobal.com/

dfarris75

  • Guest
Re: Duplicate Points - Different Point number (Land)
« Reply #12 on: November 12, 2008, 12:45:14 PM »
I'm pretty sure Map's first release was R14. :|

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #13 on: November 12, 2008, 12:59:57 PM »
OK, I did the research.  MAP Release 1.0 ran with autocad version AutoCAD R13c4a. (whatever) ;-)
Be your Best


Michael Farrell
http://primeservicesglobal.com/

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Duplicate Points - Different Point number (Land)
« Reply #14 on: November 12, 2008, 01:04:29 PM »
In the process of doing that research I found this article, where IF you believe the hype MAP, and C#D are supposed to already be totally interoperable.  And they so are not.

http://www10.giscafe.com/nbc/articles/view_weekly.php?section=Magazine&articleid=208803


Quote
Our push with Map is to have the interoperability be based on open standards. We have some open standards that we put into the product, but the fact is we don't care what the data source is, we're agnostic about it. It can come from SDE, a shape file, or from Oracle. The key is the interoperability of the data--we can create data, we can store data, and we can access that data, whether it be query and analysis or even data going out to a field application, where people are going out inspecting poles.”

“This new way supports not only polylines, polygons and feature classes but it also supports feature... It's not just the geometry that is being supported, it's features which in this case we're talking about the hydrant, pole, pipe, etc.,” explained Campbell. “'Feature' in this definition is the actual object--what users are used to working with.”
Be your Best


Michael Farrell
http://primeservicesglobal.com/