Maximum Value in Excel Column From Access

The Archn00b

Registered User.
Local time
Today, 10:07
Joined
Jun 26, 2013
Messages
76
Hi I'm using Excel vba for the first time and I'm trying to find the maxium value in the column AI (No. 35) in an Excel spreadsheet FROM Access.

So I've got:

Code:
Dim appExcel As Object
Dim datLast As Date

Set appExcel = CreateObject("Excel.Application")

datLast = appExcel.Workbooks("Path").Worksheets("Sheet1").WorksheetFunction.Max(Columns("35"))

Thanks!
 
can you link the sheet as a linked table? Then you can simply query it :)
 
Yeah I just did that in the end. Good idea.
 

Users who are viewing this thread

Back
Top Bottom