ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   view code in excel sheets (https://www.excelbanter.com/excel-programming/317628-view-code-excel-sheets.html)

jim27[_10_]

view code in excel sheets
 

Hi all

When you want to run a macro for a certain sheet continously you righ
clight the sheet tab and then click on view code and insert the macr
there.

Is there an equivalent for word documents and in fact is it possible t
have a macro run when ever word opens?

Thank

--
jim2

-----------------------------------------------------------------------
jim27's Profile: http://www.excelforum.com/member.php...fo&userid=1537
View this thread: http://www.excelforum.com/showthread.php?threadid=31985


anilsolipuram[_19_]

view code in excel sheets
 

Open a word document

macros for word works exactly same as excel

goto - tools-macro-visual basic editor, double click "this document
below project (file name)

paste this code

Private Sub Document_Open()
MsgBox "document opened"
End Su

--
anilsolipura
-----------------------------------------------------------------------
anilsolipuram's Profile: http://www.excelforum.com/member.php...fo&userid=1627
View this thread: http://www.excelforum.com/showthread.php?threadid=31985



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

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