Excel file save as with vba

Hi,

Is there an function, that when I have my main program (Excel .exe file) and let this sheet save as pdf and save it as excel. Is it possible that this excel file, have the same xlspadlock priority or an link to the main? (or that the excel file is an .exe file like the main program)

Kind Regards

You can have hyperlinks to external PDF files in your compiled workbook. This requires some tweaking as explained in the user guide (search for hyperlinks):

Dear,

That is not exactly what i mean.

I have a vba code that export a excel and a pdf file. But what i want, is that that exported excel file, have the same xlspadlock security as the main program. The main program, is used by another computer than the creator computer where xlspadlock is installed.

I hope that i informed you enough.

Kind regards

It’s not possible: the EXE file will take care of the compiled workbook (here the main workbook) and not other workbooks you may create from the main one.
But nothing prevents you from doing it yourself: it’s possible to encrypt exported workbooks with VBA code. For instance, you can use:
http://www.fmsinc.com/microsoftaccess/modules/code/GeneralVBA_VB6/EncryptionandCompression/Encryption_class.htm