ACAD.EXE PROCESS DON'T CLOSE

Discussion in 'AutoCAD' started by mrevelli, Jul 19, 2004.

  1. mrevelli

    mrevelli Guest

    In adt2005, I have a vb6 sp6 routine that's works fine but if in selection set, it founds an AECAREA , when I close ADT in my process list acad.exe remains active and I will do close it manually.
    I have also update vb script engine to 5.6 but nothing.
    I have so cycling in my selection set to eliminate AECAREA selection but nothing.
    If in my dwg there was not AECAREA that's all OK
    If I select manually my aec entities and don' select AECAREA that's all OK.
    How can I do ?
    Thanks in advance
    Max
     
    mrevelli, Jul 19, 2004
    #1
  2. mrevelli

    Joe Sutphin Guest

    AcadApplication.Quit in there somewhere?

    Joe
    --

    set, it founds an AECAREA , when I close ADT in my process list acad.exe
    remains active and I will do close it manually.
     
    Joe Sutphin, Jul 19, 2004
    #2
  3. mrevelli

    mrevelli Guest

    I have my routine compiled in a vb6 activex dll and when I call it , if in my dwg there is an aecarea when I close ADT2005 , in my process list acad.exe DON'T CLOSE and will remain active
    Thiis is the code of my VB form

    Option Explicit
    Private acad As AcadApplication
    Private doc As AecBaseDocument
    Private adtApp As AecArchBaseApplication
    Private Sub Command1_Click()
    Dim i As Integer
    Dim Ssobjs() As Variant
    Err.Clear
    Set acad = GetObject(, "Autocad.Application.16")
    Set adtApp = acad.GetInterfaceObject("AecX.AecArchBaseApplication.4.5")
    adtApp.Init acad
    Set doc = adtApp.ActiveDocument
    ReDim Ssobjs(0 To (doc.ModelSpace.Count - 1))
    '' if I exit here it works fine
    For i = 0 To doc.ModelSpace.Count - 1
    Set Ssobjs(i) = doc.ModelSpace.Item(i)
    Next
    MsgBox UBound(Ssobjs)
    '' if there isn't AECAREA works fine
    End Sub

    Thanks for an answer o a workaround
    Max
     
    mrevelli, Jul 20, 2004
    #3
  4. mrevelli

    Joe Sutphin Guest

    Set adtApp = Nothing
    Set acad = Nothing

    See if that fixes it. I'm assuming you're running this DLL from a VBA host,
    however, I don't see where you are releasing the objects listed above.

    Joe
    --

    my dwg there is an aecarea when I close ADT2005 , in my process list
    acad.exe DON'T CLOSE and will remain active
     
    Joe Sutphin, Jul 20, 2004
    #4
  5. mrevelli

    mrevelli Guest

    Hi Joe ,
    I am running from a vb activex dll call from lisp.
    Also setting
    Set adtApp = Nothing
    Set acad = Nothing
    acad.exe process 1 time close and 1 time no
    I am frustated
    Thanks in advance
    Max
     
    mrevelli, Jul 21, 2004
    #5
  6. Max, closing the opened session should do it but also
    setting the variable to Nothing should release the processs.
    But be patient, windows will unload it in a while.

    If this is not closing the acad session, it then means your session is
    either busy, or you're openning another one somewhere else.
     
    Jorge Jimenez, Jul 21, 2004
    #6
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.