Compiling VBA

P

Pat

Hi,

I am looking for information on compiling
Word VBA, first of all Word97 VBA.

Could anyone help me?

Regards,
Pat
 
P

Pat

I am looking for information on compiling
Word VBA, first of all Word97 VBA

or any other method of hiding source
program in VBA for Word.


Could anyone help me?

Regards,
Pat
 
B

Beth Melton

VBA projects can't be complied. They are dependent on a host application,
which means you need the application in order to run the code, so the
project isn't placed in a compiled state for later use in an executable file
as you can with a VB project. Please post all follow-up questions to the
newsgroup. Requests for assistance by email cannot be acknowledged.

Can you provide more information on what you mean by "hiding the source"? Do
you mean soemthing like add password protection to the project?

~~~~~~~~~~~~~~~
Beth Melton
Microsoft Office MVP

Coauthor of Word 2007 Inside Out:
http://www.microsoft.com/MSPress/books/9801.aspx#AboutTheBook

Word FAQ: http://mvps.org/word
TechTrax eZine: http://mousetrax.com/techtrax/
MVP FAQ site: http://mvps.org/
 
P

Pat

VBA projects can't be complied. They are dependent on a host application,
which means you need the application in order to run the code, so the
project isn't placed in a compiled state for later use in an executable file
as you can with a VB project.

Would it be possible to write and test VBA program first and then
to export it to VB and compile?
Can you provide more information on what you mean by
"hiding the source"? Do you mean soemthing like add
password protection to the project?

Something like password protection I would treat as minimum
because I heard that it was very easy to break such password.

Regards
Pat
 
B

Beth Melton

Pat said:
Would it be possible to write and test VBA program first and then
to export it to VB and compile?

I'm not exactly sure what you are asking, or rather what you are trying to
do. Once you take the VBA Project to VB then you need to add a Word Object
reference and modify the code accordingly. It won't run "as-is". So at that
point you would need to write and test again. And if you are automating Word
then there's even more to take into consideration than a few simple
modifications to the code. If that's what you want to do then I'd start it
in VB and not Word. Are you trying to create a VB project or a Word project?
What does your code do exactly?
Something like password protection I would treat as minimum
because I heard that it was very easy to break such password.

That is correct. Perhaps you can expand on what you are trying to do
exactly. Also, you may want to post in one of the Word VBA newsgroups.
You'll likely get a wider audience in order to obtain ideas for the solution
you are seeking. :)

Please post all follow-up questions to the newsgroup. Requests for
assistance by email cannot be acknowledged.

~~~~~~~~~~~~~~~
Beth Melton
Microsoft Office MVP

Coauthor of Word 2007 Inside Out:
http://www.microsoft.com/MSPress/books/9801.aspx#AboutTheBook

Word FAQ: http://mvps.org/word
TechTrax eZine: http://mousetrax.com/techtrax/
MVP FAQ site: http://mvps.org/
 
P

Pat

VBA projects can't be complied. They are dependent on a host application,
I'm not exactly sure what you are asking, or rather what you are trying to
do. Once you take the VBA Project to VB then you need to add a Word Object
reference and modify the code accordingly. It won't run "as-is". So at that
point you would need to write and test again. And if you are automating Word
then there's even more to take into consideration than a few simple
modifications to the code. If that's what you want to do then I'd start it
in VB and not Word. Are you trying to create a VB project or a Word project?
What does your code do exactly?


That is correct. Perhaps you can expand on what you are trying to do
exactly. Also, you may want to post in one of the Word VBA newsgroups.
You'll likely get a wider audience in order to obtain ideas for the solution
you are seeking. :)

Thank you very much. I have to think over your answer.

Regards,
Pat
 
P

Pat

Hi again,

Have you heard about using any obfuscator
for VBA (Word97 or later)?

Regards,
Pat
 
B

Beth Melton

Pat said:
Hi again,

Have you heard about using any obfuscator
for VBA (Word97 or later)?

I don't think there are obfuscators for VBA. If I'm not mistaken, VBA
doesn't have the ability to redefine keywords and operators which is needed
for obfuscation.

To be honest, I don't have a lot of experience in securing VBA projects
other than password protecting the project. That's always served my needs,
but I know it's not 100%, just as most things aren't anyway. I do know that
later versions of Word, starting around Word 2000, do have better encryption
methods than previous versions so you might want to look a little further
into the password protection method. You might also ask in one of the Word
VBA newsgroups for more input. I think all you're getting here is mine and
it's possible I'm not thinking of something. I prefer to have more than one
set of knowledgeable eyes for questions, that way I know you're getting the
best answer. :)

Please post all follow-up questions to the newsgroup. Requests for
assistance by email cannot be acknowledged.

~~~~~~~~~~~~~~~
Beth Melton
Microsoft Office MVP

Coauthor of Word 2007 Inside Out:
http://www.microsoft.com/MSPress/books/9801.aspx#AboutTheBook

Word FAQ: http://mvps.org/word
TechTrax eZine: http://mousetrax.com/techtrax/
MVP FAQ site: http://mvps.org/
 
P

Pat

I don't think there are obfuscators for VBA. If I'm not mistaken, VBA
doesn't have the ability to redefine keywords and operators which is needed
for obfuscation.

To be honest, I don't have a lot of experience in securing VBA projects
other than password protecting the project. That's always served my needs,
but I know it's not 100%, just as most things aren't anyway. I do know that
later versions of Word, starting around Word 2000, do have better encryption
methods than previous versions so you might want to look a little further
into the password protection method. You might also ask in one of the Word
VBA newsgroups for more input. I think all you're getting here is mine and
it's possible I'm not thinking of something. I prefer to have more than one
set of knowledgeable eyes for questions, that way I know you're getting the
best answer. :)

Thank you very much.
I have been adviced to hide my code by moving
major code logic into an VB ActiveX DLL project.
I am trying to find out more about that at the moment.

Regards
Pat
 

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