See the top rated post in this thread. Click here

Results 1 to 5 of 5

Thread: Help ! I want to turn on isometric snap with one click or command

  1. #1
    100 Club
    Join Date
    2007-10
    Location
    God's Own Country
    Posts
    183
    Login to Give a bone
    0

    Default Help ! I want to turn on isometric snap with one click or command

    Hi,
    I want to turn on isometric snap with one click or a single command,
    so I trying to write a code, but its always fail.
    Now you guys are the only way, please look.

    (defun c:iso ()
    (if (= "snapstyl" "0")
    (if (= "snapstyl" "1")
    (command "snapstyl" "1") (command "snapstyl" "0")))
    (princ)

  2. #2
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,805
    Login to Give a bone
    1

    Default Re: Help ! I want to turn on isometric snap with one click or command

    Try this:

    Code:
    
    (defun c:iso ()
      (setvar "snapstyl" (abs (- 1 (getvar "snapstyl"))))
    )
    
    R.K. McSwain | CAD Panacea |

  3. #3
    100 Club
    Join Date
    2007-10
    Location
    God's Own Country
    Posts
    183
    Login to Give a bone
    0

    Smile Re: Help ! I want to turn on isometric snap with one click or command

    Woof ! thank you.
    but, what s the abs function?


    Quote Originally Posted by rkmcswain View Post
    Try this:

    Code:
    
    (defun c:iso ()
      (setvar "snapstyl" (abs (- 1 (getvar "snapstyl"))))
    )
    

  4. #4
    I could stop if I wanted to
    Join Date
    2007-05
    Location
    Brookfield WI
    Posts
    331
    Login to Give a bone
    1

    Default Re: Help ! I want to turn on isometric snap with one click or command

    Quote Originally Posted by sandeepk View Post
    Woof ! thank you.
    but, what s the abs function?
    Go to developer help > autolisp reference > autolisp functions > A functions > first one in list is abs

    Hit F1 in editor, or look for developer help in standard help menu

    for info on snapstyl, type sysvdlg, place cursor in list and hit s, scroll to snapstyl to read about the system variable that he changed

  5. #5
    100 Club
    Join Date
    2007-10
    Location
    God's Own Country
    Posts
    183
    Login to Give a bone
    0

    Smile Re: Help ! I want to turn on isometric snap with one click or command

    Hmmmmmm.. nice
    I'll dig it. sure
    Thank you
    Sandeep


    Quote Originally Posted by d_m_hopper View Post
    Go to developer help > autolisp reference > autolisp functions > A functions > first one in list is abs

    Hit F1 in editor, or look for developer help in standard help menu

    for info on snapstyl, type sysvdlg, place cursor in list and hit s, scroll to snapstyl to read about the system variable that he changed

Similar Threads

  1. Turn SNAP off when selecting objects
    By autocad.wishlist1734 in forum AutoCAD Wish List
    Replies: 13
    Last Post: 2012-12-06, 04:59 AM
  2. Problems with isometric snap
    By chrispw in forum AutoCAD 3D (2007 and above)
    Replies: 4
    Last Post: 2011-11-22, 09:14 AM
  3. ACAD LT 2000 Isometric Snap Style?
    By tedg in forum AutoCAD LT - General
    Replies: 2
    Last Post: 2010-04-02, 07:28 PM
  4. Create Button for Isometric Snap
    By sandeep_koodal in forum AutoCAD General
    Replies: 1
    Last Post: 2009-06-22, 12:08 PM
  5. right click for object snap
    By sherflor in forum AutoCAD Customization
    Replies: 2
    Last Post: 2009-05-01, 05:11 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
  •