Thank you, but I am 99% sure that bit of the code works okay. The sEmployeeIdRangeA variable is set to change each time so that it selects the next row. The problem is that I am unable to assign the value of the recordset to the variable iEmployeeCode. The code returns a "Run-time error 13 Type Mismatch" error when I try to run it. I know that its erroring at the "iEmployeeCode = rs.GetRows" line because when I rem it out the code runs through error free.
Thank you
Main Topics
Browse All Topics





by: saurabh726Posted on 2008-10-22 at 04:51:32ID: 22775469
Replace these lines with...
1)
sEmployeeIdRangeA = "A" & i
sEmployeeIdRangeB = "B" & i
This with....
sEmployeeIdRangeA=cells(i,
sEmployeeIdRangeB = cells(i,2)
Saurabh...