I can now get the data from the Workbook/sheet in QC.
I store the values into an array so I don't have to keep the Workbook and sheets in memory.
Dim Rows_Count, i
Dim FOOD: FOOD = 0
Dim DRINK: DRINK = 1
' Set the file pointing to QC.
filepath = "[QualityCenter\Resources] Resources\ABC\DEF\GHI" Ď donít include .xls.
Set myExcel = createobject("Excel.application")
Set myFile = myExcel.Workbooks.Open(PathFinder.Locate(filepath) )
Set mySheet = myFile.Worksheets("Sheet1")
Rows_Count = mySheet.usedrange.rows.count
' Create an array for easier access to contents of Excel sheet.
For i = 2 to (Rows_Count )
ReDim Preserve aRR( 1, i - 2 )
aRR(FOOD,i-2) = mySheet.cells(i, "A")
aRR(DRINK,i-2) = mySheet.cells(i, "B")
Set myExcel = Nothing
Set myFile = Nothing
Set mySheet = Nothing
When in Florida, Don't Tampa with the code. I made this up.