Welcome to the VanDyke Software Forums

Join the discussion today!


Go Back   VanDyke Software Forums > Scripting

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 01-21-2005, 02:45 AM
bojankus bojankus is offline
Registered User
 
Join Date: Dec 2004
Posts: 4
A tricky one - Script starting excel with macro

hello,

im trying to start excel with macro in it and than start the macro...i dont know what commands must i use in vbs to start excel than set "Enable macro" and for the cheery on top start the macro...

ehhhmm...a little help woud be appreciated mucho...

nice day everyone,
Bojankus
Reply With Quote
  #2  
Old 01-24-2005, 02:55 PM
jdev's Avatar
jdev jdev is offline
VanDyke Technical Support
 
Join Date: Nov 2003
Location: Albuquerque, NM
Posts: 1,085
I think that you can circumvent the problem altogether by signing your macro code, which will cause a macro to be executed automatically, without the security prompt. For more information, search in Excel's help for steps to digitally sign a macro project.
__________________
Jake Devenport
VanDyke Software
Technical Support
YouTube Channel: https://www.youtube.com/vandykesoftware
Email: support@vandyke.com
Web: https://www.vandyke.com/support
Reply With Quote
  #3  
Old 02-14-2005, 09:28 AM
wasodg2 wasodg2 is offline
Registered User
 
Join Date: Dec 2004
Location: Spokane, WAshington
Posts: 16
Talking Got this from the another post

'Code for running excel macro in vbs
Dim xlApp
Dim xlWkb


Set xlApp = CreateObject("excel.application")
Set xlWkb = xlApp.Workbooks.Open("YOUR WORKBOOK")

xlWkb.RunAutoMacros 1 'xlautoopen
xlApp.Run ("YOUR MACRO")

xlApp.Visible = True
Set xlWkb = Nothing
Set xlApp = Nothing

More info here
http://msdn.microsoft.com/library/de...HV05186508.asp

Hope this helps
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 02:25 AM.