-Custom "Object Snap" -Snap Between, -AutoCad 2000i Map/Win XP

Discussion in 'AutoCAD' started by MS, Dec 16, 2003.

  1. MS

    MS Guest

    Hello.

    I need some help please?

    I want to make a "snap-function" that gives me a point(midpoint) between to
    other point.,
    e.g. I have two circles and want to start drawing a line from a point
    exactly between the two center of these circles.
    ( I could draw a line from center to center and start drawing from midpoint
    of that line,
    but I hope you can helpe me make a "snap between two points" instead).

    At an aplication called "Point & NovaPoint 5.5" I can use a command called
    "Osnap between" ,
    it's a macro but I don't know how they have made it.....

    Hope someone can understand what I am talking about here (sorry, my language
    is all to bad).

    I use:
    Win XP and AutoCad 2000i Map.


    Thanks for any help.

    Br
    Morten S
     
    MS, Dec 16, 2003
    #1
  2. MS

    Jim Claypool Guest

    (defun between ( / pt1 pt2)
    (while (not (setq pt1 (getpoint "\nSelect first point: "))))
    (while (not (setq pt2 (getpoint "\nSelect second point: "))))
    (polar pt1 (angle pt1 pt2) (/ (distance pt1 pt2) 2.0))
    )
     
    Jim Claypool, Dec 16, 2003
    #2
  3. MS

    TRJ Guest

    Use AutoCAD's geometry calculator as in: (note the apostrophe preceeding
    CAL)

    LINE Specify first point: 'CAL
     
    TRJ, Dec 16, 2003
    #3
  4. MS

    R.K. McSwain Guest

    In addition to TRJ's suggestion, the calculator has a built in shortcut MEE that returns the midpoint between two endpoints
    [otherwise known as (end+end)/2]
     
    R.K. McSwain, Dec 16, 2003
    #4
  5. MS

    MS Guest

    Hello.

    This one looks to be the one I need,
    but I can't make it work. Sorry.

    Shall I copy the txt in to a lsp-file?
    Or use it as a macro on a new button?
    Or?



    Morten
     
    MS, Dec 16, 2003
    #5
  6. MS

    Jim Claypool Guest

    If you have a custom menu, put the code in an mnl file the same name as the
    menu,
    otherwise put the code in an acad.lsp file. You'll probably have to create
    it.

    Then create a button to execute it.
     
    Jim Claypool, Dec 16, 2003
    #6
  7. MS

    MS Guest

    Hi.

    I still have some problems about activateing the command, (have tried .lsp
    and .mnl and a button to activate)
    but I will fix it, I hope...

    Thank you Jim.

    Morten
     
    MS, Dec 17, 2003
    #7
  8. MS

    MS Guest

    Hi


    Thanks for your respond.

    Morten


     
    MS, Dec 17, 2003
    #8
  9. MS

    MS Guest

    Hi


    Thanks for your respond.

    Morten


    In addition to TRJ's suggestion, the calculator has a built in shortcut MEE
    that returns the midpoint between two endpoints
    [otherwise known as (end+end)/2]
     
    MS, Dec 17, 2003
    #9
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.