I am creating a command button then adding code with this syntax.
With objActiveWkb.VBProject.VBComponents("Sheet1").CodeModule
StartLine = .CreateEventProc("Click", strButtonName) + 1
.InsertLines StartLine, _
" Sheets(" & """" & rsCoverSheet!TabName & """" &
").Select" & vbCrLf
End With
The spreadsheet is created, the button is created, the code is
created, the spreadsheet is saved and closed.
But the "Microsoft Visual Basic - VBA Project" remains open. What is
the syntax to close it?
Jim Rech - 21 Dec 2007 14:24 GMT
It's a long time peculiarity of the VBE that it does not always seem to know
that a given project's workbook has been closed. It's annoying but it does
no harm as far as I know.

Signature
Jim
|I am creating a command button then adding code with this syntax.
|
[quoted text clipped - 10 lines]
| But the "Microsoft Visual Basic - VBA Project" remains open. What is
| the syntax to close it?