Reading Excel Strikethrough Property via OLEDB
Posted on 2008-06-18
I have a module in an Access 2003 project that opens an OLEDB connection to an Excel 2003 document. The code looks something like this:
Public Sub ConnectToExcel()
Dim cn As New ADODB.Connection
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\myexcel.xls;Extended Properties='Excel 8.0;HDR=Yes;IMEX=1';"
Dim rst As New ADODB.Recordset
rst.Open ("SELECT * FROM [Sheet1$]"), cn, adOpenDynamic, adLockOptimistic
Do Until rst.EOF = True
If Len(rst(1) > 0) Then
I'd like to select only the records where the strikethrough property of the cell in column B is FALSE. Does anyone know how to accomplish this?
Thanks in advance.