Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to tell if a worksheet exist in a workbook

Status
Not open for further replies.

LonnieJohnson

Programmer
Apr 16, 2001
2,628
US
I have an access application that opens an excel workbook that has about 10 worksheets and writes data to each worksheet.

I have a query that has a corresponding record for each worksheet. Sometimes there is an extra record or two that do not have a corresponding sheet and they overwrite the data that is in the sheet.

My question is how can I tell if a worksheet exist in an excel workbook via vba?



ProDev, MS Access Applications
Visit me at ==>
May God bless you beyond your imagination!!!
 
You can open the workbook via automation and check the worksheets collection.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top