Auto run a macro

G

Guest

Hi,

Can anyone please tell me how to run a macro automatically from the
VB-editor when opening the spreadsheet ?

Br,
Jakob
 
Z

Zone

You can put this in the workbook module:

Private Sub Workbook_Open()
'your code here
End Sub

or you can put this in a standard module:

Sub Auto_open()
'your code here
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top