Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Disable macro in excel automation with VC++/Win2k

Hi,
I have a problem trying to automate an excel file from Visual C++ in
Win2k. The installed version of Excel is 2000. I need to disable all
macros before loading. Could you help me?
Thank you.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Disable macro in excel automation with VC++/Win2k

You can disable events with

Application.EnableEvents = False

That is the VBA way - you would have to adapt it to C++

--
Regards,
Tom Ogilvy
"mbozzaotre" wrote in message
oups.com...
Hi,
I have a problem trying to automate an excel file from Visual C++ in
Win2k. The installed version of Excel is 2000. I need to disable all
macros before loading. Could you help me?
Thank you.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Disable macro in excel automation with VC++/Win2k

I tried in this way, but it had no effect in my application :-(

Finding another solution, i noticed that the macro secutity level
option setted to high disable the macro execution loading the file by
excel application. Is it also possible to set the macro security level
in automation mode?

Tom Ogilvy ha scritto:
You can disable events with

Application.EnableEvents = False

That is the VBA way - you would have to adapt it to C++

--
Regards,
Tom Ogilvy
"mbozzaotre" wrote in message
oups.com...
Hi,
I have a problem trying to automate an excel file from Visual C++ in
Win2k. The installed version of Excel is 2000. I need to disable all
macros before loading. Could you help me?
Thank you.


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Disable macro in excel automation with VC++/Win2k

I believe it is a registry setting, so you could change the registry setting
before starting excel. You might search this group for the key/bits you
have to set. I know it has been posted for xl97, but don't know if it has
(or is the same) for xl2000 or later.

--
Regards,
Tom Ogilvy

"mbozzaotre" wrote in message
oups.com...
I tried in this way, but it had no effect in my application :-(

Finding another solution, i noticed that the macro secutity level
option setted to high disable the macro execution loading the file by
excel application. Is it also possible to set the macro security level
in automation mode?

Tom Ogilvy ha scritto:
You can disable events with

Application.EnableEvents = False

That is the VBA way - you would have to adapt it to C++

--
Regards,
Tom Ogilvy
"mbozzaotre" wrote in message
oups.com...
Hi,
I have a problem trying to automate an excel file from Visual C++ in
Win2k. The installed version of Excel is 2000. I need to disable all
macros before loading. Could you help me?
Thank you.




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with excel macro - getting automation error [email protected] Charts and Charting in Excel 3 October 24th 07 05:22 PM
VB6 Excel 97 code no longer works if Win2K SP3/4 applied. Tim R[_3_] Excel Programming 5 October 10th 04 06:24 AM
How to create a VB macro in Excel from Automation... Cristian Godoci Excel Programming 1 August 5th 04 04:17 PM
Macro 'Automation error' with ChemOffice Excel macro Stew Excel Programming 0 October 27th 03 08:26 PM
Disable macro through automation Scott Wallace Excel Programming 2 October 15th 03 07:26 PM


All times are GMT +1. The time now is 09:08 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"