Can we disable macro security using Visual Basic for Applications scripting in Word 2003?

  • Thread starter Jean-Guy Marcil
  • Start date
J

Jean-Guy Marcil

oc9ine said:
Hi,

I have win xp sp3. I use Office 2003. I want to have certain things done
automatically

using Visual Basic for Applications in my Word documents for which I
require that Macro security be

set to lowest level or disabled for that period so that my required things
could be done in that

particular document. Besides I share my computer with family and I am my
computer's sole

administrator.

Can we disable macro security using Visual Basic for Applications scripting
in Word 2003? If Yes plz

provide example code ?

Can you imagine the huge security flaw that would exist if we could do that?

If you are using your own home computer and are the administrator, why don't
you just permanantly set the security to high and place your templates
containing macros in your "User Templates" folder as defined under Tools >
Options > File Locations?
This way, macros will run without any problems becasue it is a "trusted"
location.
 
O

oc9ine

Hi,

I have win xp sp3. I use Office 2003. I want to have certain things done
automatically

using Visual Basic for Applications in my Word documents for which I
require that Macro security be

set to lowest level or disabled for that period so that my required things
could be done in that

particular document. Besides I share my computer with family and I am my
computer's sole

administrator.

Can we disable macro security using Visual Basic for Applications scripting
in Word 2003? If Yes plz

provide example code ?

Thanx,


Oc9ine.
 
J

Jonathan West

Look, those who provide most of the answers here are generally responsible
people. Even if we happen to know how to do what you are asking (and as it
happens, I don't), it is hardly likely that we would publisg a mechanism
that would be of use in spreading viruses.

In any case, Nometz must initially be running something other than VBA,
because if it were VBA, it wouldn't get the chance to execute in the first
place in order to make the changes to security that allow it to propagate.

If you need a specific macro or template to be given execution rights, use
"Digital Certificate for VBA Projects" in Microsoft Office Tools to create
a digital certificate, and apply the certificate to your template. Then
macros from that template then will run on your PC without triggering the
macro warning.
 
O

oc9ine

Dear I found this on net...

========

Nometz is a macro virus that infects all opened Microsoft Word documents.
The parasite modifies Microsoft Word essential macro security settings,
hides certain menu options and disables some program components. Nometz
copies infected documents to C:\Windows\System directory, changes their
extension to .jpg and silently uploads these files to a predetermined FTP
server. Such virus behavior causes a disclosure of user sensitive
information. After documents were successfully uploaded, the parasite
deletes them and temporarily restores default Microsoft Word security
settings.


=========

I ask there must be some hidden for-masters-only settings to disable macro
security of VBA, plz I want to do it for my personal purpose only..


Help me..


Oc9ine
 
D

Doug Robbins - Word MVP

I would not think that it is necessary to use the Word Object Model to
achieve what that virus purportedly does and that the description of how it
does it is incorrect.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 
M

macropod

Hi oc9ine,

One thing you can be sure of is that the virus wasn't using vba to change the macro security level.

To be sure, the security settings can be modified programmatically, but not using vba in Word when the Word macro security settings
are set to 'high' - unless it's being run from a trusted location. The reason is simple: if you load a document containing a macro,
Word checks the security settings before allowing the macro to run. Hence there's no way for a security-setting-change macro to run
when the security settings are set to 'high' - unless it's being run from a trusted location (in which case, why bother).
 

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