ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How can a macro automatically initiate uponing a file? (https://www.excelbanter.com/excel-discussion-misc-queries/23801-how-can-macro-automatically-initiate-uponing-file.html)

kanye

How can a macro automatically initiate uponing a file?
 
I'd like to set a macro so that when the file is opened, it automatically runs.

Bob Phillips

Put the code in the Workbook_Open event in the Thisworkbook code module.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"kanye" wrote in message
...
I'd like to set a macro so that when the file is opened, it automatically

runs.



kanye

I've located the Thisworkbook code module, but see nothing about
Workbook-Open event. Where do I look for this?

"kanye" wrote:

I'd like to set a macro so that when the file is opened, it automatically runs.


JulieD

see my response to the question you posted 1 min before the one Bob answered
.... titled "Automatic Message"

--
Cheers
JulieD
check out www.hcts.net.au/tipsandtricks.htm
....well i'm working on it anyway
"kanye" wrote in message
...
I've located the Thisworkbook code module, but see nothing about
Workbook-Open event. Where do I look for this?

"kanye" wrote:

I'd like to set a macro so that when the file is opened, it automatically
runs.




Bob Phillips

Input this into the Thisworkbook code mould

Private Sub Workbook_Open()

End Sub

and add your code to it.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"kanye" wrote in message
...
I've located the Thisworkbook code module, but see nothing about
Workbook-Open event. Where do I look for this?

"kanye" wrote:

I'd like to set a macro so that when the file is opened, it

automatically runs.



kanye

Thanks to you both, this works well.

"kanye" wrote:

I'd like to set a macro so that when the file is opened, it automatically runs.



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

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