Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA Excel Error 2029

Status
Not open for further replies.

johnnymagee

Programmer
Apr 19, 2005
26
GB
I have a spreadsheet with dates in Column A, unit names along the top and a whole lot of vlookups on the eomonth of the dates in between. For some reason when I use VBA to read this matrix into a database, it returns "Error 2029" as the value for each vlookup.
I have a simple workaround to replace the eomonth for this but it seems odd. Anyone know why it happens?
 
And the code you use to read the matrix? How about posting that please.

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 


I'd bet, it I were a betting man, that you are having an issue with DATES.

Why do Dates and Times seem to be so much trouble? faq68-5827


Skip,

[glasses] [red]Be Advised![/red]
A wee deranged psychic may be runnin' around out there!
SMALL MEDUIM @ LARGE[tongue]
 
well the code is very boring,. In effect:

for lCol = 2 to lNumCols
sUnit = sht.cells(1,lCol)
for lRow = 2 to lNumRow
dDay = sht.ceslls(lRow,1)
debug.print sht.cells(lrow,lcol)
next
next

sUnit and dDay return correct values but the vlookup in
sht.cells(lrow,lcol) returns "Error 2029", but its fine in the spreadsheet
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top