I have tried to define a lastrow code that would return the last row value of the last non empty cell in a excel table. (ITS FORMATTED AS A TABLE)
My exceltable have values in COL A from 1 to 1005, COL B from 1 to 414 and in COL C from 414 to 1005.
What i want is to have one lastrow code that returns 414 and one that returns 1005. The problem i get is that because it is in a table. my codes
lastrow3 = ThisWorkbook.Worksheets("Data?nskem?l").Range("A" & Rows.Count).End(xlUp).Row
lastrow2 = ThisWorkbook.Worksheets("Data?nskem?l").Range("B" & Rows.Count).End(xlUp).Row
Both return 1005. Can i get around this with my table or is it a formating issue of some sort?
Best regards and thanks in advance
/D
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…