ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How to run a macro in word web page (https://www.excelbanter.com/excel-programming/287085-how-run-macro-word-web-page.html)

jackie

How to run a macro in word web page
 
please help!
I will like to create a command botton in word to call
that macro in word web page. basically, the final product
is viewed in word. I was able to use the command botton
but i am not able to have it run the marco. And COLO how
could i make it invisible?

COLO helped me and send me this code but it does not
work. and some posted something else so i have create a
new post.
Private Sub CommandButton1_Click()
Dim oXl As Object
Set oXl = CreateObject("Excel.Application")
'Or if XL wkb is already opened use GetObject instead.
'And do not have to be visibled and to be opened.
With oXl
.Visible = True
.workbooks.Open ("C:\Book1.xls")
.Application.Run "Macro1"
End With
Set oXl = Nothing
End Sub


but this is telling me to search for help. even when i
copy the code from excel to word.
that u
..




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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com