Thnx, will do with the collection.
No need to read from table.
Prefer this
instead of using two select cases in the loop.Code:For iCount = 1 To oXLees.Worksheets.Count strSht = oXLees.Worksheets(iCount).Name iTxt = InStr(1, strSht, " ") oXLsht.Cells(iCount, 1).Value = XLxRef.Item("Eclair." & Trim(Mid$(strSht, 1, iTxt - 1))) oXLsht.Cells(iCount, 2).Value = XLxRef.Item("Chocolade." & Trim(Mid$(strSht, iTxt + 1))) Next




Reply With Quote