programatically recompile VBA project

A

AL

Hi all,

I am uainf Excel 2000 VBA to try to recompile the vb project froom VBS code:

Sub RecompileVBA()


Dim VBProj As VBProject
Set VBProj = ThisWorkbook.VBProject


VBProj.BuildFileName = ActiveWorkbook.Name
VBProj.MakeCompiledFile

End Sub


I got a run time error 748 "method or property is not valid in this type of
project.


I save the workbook in name of Book1.xls.


THanks

Alex
 
T

Tom Ogilvy

Don't believe Excel supports making a DLL. Perhaps if you have the
developer edition - can't say about that.
 
M

Myrna Larson

Excel will "compile on demand". Is there some reason this is not sufficient
for your needs? I don't know of any way to force a recompile other than
perhaps running a procedure in the file.
 

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. After that, you can post your question and our members will help you out.

Ask a Question

Top