close the window

Discussion in 'AutoCAD' started by john m, Jan 27, 2004.

  1. john m

    john m Guest

    Hello,
    I know i have seen this somewhere..
    How to temporarily close the user form and allow the user to pan and
    zoom and then hit return to get the program back?

    thanks in advance for any response
    jm
     
    john m, Jan 27, 2004
    #1
  2. john m

    Norman Yuan Guest

    Form1.Hide 'Hide user form to allow user to get input from Acad Editor

    Dim pt As Variant

    pt=ThisDrawing.Utility.GetPoint(, vbCr + "Pick a point: " )

    Form1.Show 'Show user form or do futher process based on user input
     
    Norman Yuan, Jan 28, 2004
    #2
  3. john m

    john m Guest

    I guess i asked the wrong question.
    what i really want to do is to interface with autocad with the window still
    open!
    but thanks
     
    john m, Jan 28, 2004
    #3
  4. john m

    Norman Yuan Guest

    Basically, VBA's UserForm is displayed as modal form (i.e. dialog box), when
    it is displayed, you cannot interact with Acad unless you hide it or unload
    it. Using UserForm.Hide() and UserForm.Show is standard way to interact Acad
    during a VBA process.

    However, since Acad2Ki, you can open a UserForm as modeless window (but it
    was useless in Acas2Ki because it does not keep focus on itself ). Acad2002
    or later comes a file "AcFocusCtrl" that helps to keep focus on the form, so
    that you can keep the UserForm open while do something in ACAD. Search the
    group with keyword "focus", you may get a few posts on this topic.
     
    Norman Yuan, Jan 29, 2004
    #4
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.