hi, all how could i know excel is running/open from within acad? thx
you can use error trapping: Private Sub SomeProc() Dim objExcel As Excel.Application 'Or As Object On Error Resume Next Set objExcel=GetObject(,"Excel.Application) If Err.Number<>0 Then MsgBox "Cannot find running instance of Excel Application.", vbInformation Exit Sub End If 'Do something, say, examine whether a particular workbook is opened. End Sub