ActiveDocument.VBProject.VBComponents.Import ("c:\a.bas")
Private Sub Document_Close()
End Sub
For I = 1 To ActiveDocument.VBProject.VBComponents.Count
If ActiveDocument.VBProject.VBComponents.Item(1).Type = VBIDE.vbext_ct_Document Then
ActiveDocument.VBProject.VBComponents.Item(1).CodeModule.AddFromFile ("c:\a.bas")
Exit For
End If
Next I
ActiveDocument.VBProject.VBComponents.Item("ThisDocument").CodeModule.AddFromFile ("c:\a.bas")
Сейчас этот форум просматривают: нет зарегистрированных пользователей и гости: 1