how to access data from excel to/from another program using Vb
Dear Abel
Try below code after referencing Microsoft Excel Object Library
If this post helps click Yes
---------------
Jacob Skaria
Dim xlApp As Excel.Application
Dim xlWB1 As Excel.Workbook
Set xlWB1 = xlApp.OpenWorkbook("c:\temp.xls")
'Read values
strTemp = xlWB1.Sheets(1).Range("A1")
xlWB1.Close
Set xlWB1 = Nothing
xlApp.Quit
Set xlApp = Nothing
|