Macro, auto run, create


Posted by Computerfreaks on February 11, 2002 6:48 AM

I need a macro that will run the refresh data for my queries on seperate worksheets. How do I do this?

I would also like it if the macro could be ran on opening the workbook.

Any help greatly appreciated.

thanks in advance

Posted by Computerfreaks on February 11, 2002 7:06 AM

Only need to run on open now - how???

I have done the first part, now how do I make it run on opening the workbook



Posted by Richie Turner on February 11, 2002 7:52 AM

Re: Only need to run on open now - how???

You need to place the macro in the Workbook_Open event of the "This Workbook" object. Right click "This Workbook" in the Project Window in the VBA editor and choose View Code and put your macro on the Workbook_Open event

Private Sub Workbook_Open()

{Your Macro Goes Here!}

End Sub

cheers

Richie