+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    Full Member pryzmm's Avatar
    Computer Details
    pryzmm's Computer Details
    Operating System:
    Windows XP
    Using
    AutoCAD 2009
    Join Date
    Jul 2007
    Posts
    54

    Default Just another routine, pls take a look

    Registered forum members do not see this ad.

    hi, i made this to do the following;

    Code:
    ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;        
    ;;   1) This routine will turn ALL layers (on/thaw/unlock) state.
    ;;   2) It will then select all the layers.
    ;;   3) Then move (NOT FLATTEN) everything to 0,0,0 coordinates 
    ;;       with a basepoint input from the user.
    ;;       -->> by pryzmm 072007 !!! 
    ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
    (DEFUN C:000 ()
      (setvar "cmdecho" 0)
      (command "-layer" "u" "*" "t" "*" "on" "*" "" "") 
      (setvar "osmode" 33)
      (princ "\nSelect base point->> hint (any end or intersection point):")
      (setq p1 (getpoint))   
      (command "move" "all" "" p1 "0,0,0" )  
      (setvar "osmode" 167)
      (setvar "cmdecho" 1) 
      (prompt "......................done !!! ")(terpri)    
      (princ)); end
    this works fine , but what i really want is something like the sequence below;

    (defun c:000 ()
    (mapped all the current layer state and save in memory)
    (turn all the layers (on/thaw/unlock) if its find one that is
    (off/freeze/locked))
    (select all layers and move to 0,0,0 with a basepoint from user)
    (change back all the layers to its previous state using the 1st line string of command or any other string));end of routine

    any suggestion ,,,gurus and coders alike ???

    i use autocad 2006

  2. #2
    Senior Member devitg's Avatar
    Computer Details
    devitg's Computer Details
    Operating System:
    XP
    Monitor:
    VG2021WM VIEW SONIC
    Using
    AutoCAD 2008
    Join Date
    Apr 2005
    Location
    CORDOBA ARGENTINA
    Posts
    107

    Default

    If you do a (SSGET "x") will do a selection set of all enty on all layers

    (ssget "X") creates a selection set of all entities in the drawing including those on layers that are frozen or off.
    But i will not do allow to move LOCKED layer
    Last edited by devitg; 27th Jul 2007 at 06:15 pm. Reason: I talk before think

  3. #3
    Full Member pryzmm's Avatar
    Computer Details
    pryzmm's Computer Details
    Operating System:
    Windows XP
    Using
    AutoCAD 2009
    Join Date
    Jul 2007
    Posts
    54

    Default

    devitg, could you exactly code that for me pls. im blurrr in this kind if codes, all i knew are those very basic ones,,,,plssssss...thanks

  4. #4
    Senior Member devitg's Avatar
    Computer Details
    devitg's Computer Details
    Operating System:
    XP
    Monitor:
    VG2021WM VIEW SONIC
    Using
    AutoCAD 2008
    Join Date
    Apr 2005
    Location
    CORDOBA ARGENTINA
    Posts
    107

    Default

    Quote Originally Posted by pryzmm View Post
    devitg, could you exactly code that for me pls. im blurrr in this kind if codes, all i knew are those very basic ones,,,,plssssss...thanks
    Hi pryzmm , I´m dealing with it , I have a question , the basepoint selected by the user will be on a ON, THAW, UNLOCK layer???

  5. #5
    Senior Member devitg's Avatar
    Computer Details
    devitg's Computer Details
    Operating System:
    XP
    Monitor:
    VG2021WM VIEW SONIC
    Using
    AutoCAD 2008
    Join Date
    Apr 2005
    Location
    CORDOBA ARGENTINA
    Posts
    107

    Default Here is my code

    Quote Originally Posted by pryzmm View Post
    devitg, could you exactly code that for me pls. im blurrr in this kind if codes, all i knew are those very basic ones,,,,plssssss...thanks
    It take te base point on a on and thaw layer.
    Attached Files

  6. #6
    Full Member pryzmm's Avatar
    Computer Details
    pryzmm's Computer Details
    Operating System:
    Windows XP
    Using
    AutoCAD 2009
    Join Date
    Jul 2007
    Posts
    54

    Default

    Registered forum members do not see this ad.

    hi, thanks for that but could anyone pls. help on how exactly where to put this string in the above,,,,plsssss thanks guys in advance

Similar Threads

  1. LDD Points Routine
    By pkendall in forum Civil 3D & LDD
    Replies: 2
    Last Post: 30th Jun 2008, 01:56 pm
  2. I need a lisp routine
    By Andrew in forum AutoLISP, Visual LISP & DCL
    Replies: 4
    Last Post: 28th Apr 2007, 02:57 pm
  3. Can anyone help me with this lisp routine?
    By rookie37 in forum AutoCAD 3D Modelling & Rendering
    Replies: 1
    Last Post: 19th Mar 2007, 02:32 am
  4. Run a LISP ROUTINE
    By CADken in forum AutoCAD Beginners' Area
    Replies: 2
    Last Post: 9th Aug 2006, 12:02 am
  5. AutoLisp Routine
    By ride in forum AutoCAD Beginners' Area
    Replies: 2
    Last Post: 15th Mar 2005, 09:58 pm

Bookmarks

Posting Permissions

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