View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
JLGWhiz JLGWhiz is offline
external usenet poster
 
Posts: 3,986
Default When excel is opened need to ask a question

Press Alt + F11 to open the VBE, then double click ThisWorkbook in the projet
window located upper left in the VBE window. After you add your macro name
to the code below, paste it into the ThisWorkbook code window. When you open
that workbook, the code will run. The macro you call must be in the standard
code module1.

Private Sub Workbook_Open()
MsgBox "This is " & Format(Date, "dddd, d, m")
Call 'macro name
End Sub

If the macro takes arguments the arguments must be included in partheses,
otherwise, omit the parentheses.

" wrote:

What day of the week it is and open a certian workbook and run a
certain macro. New to this and need some help. Do now somewhat about
vb that works inside of excel.
I would be Thankful for any help..