I asked the question yesterday but the answers could not solve it... Selecting a range until at least one column has numeric value
The problem is:
I have a range of some columns and some rows which is a reference, so the formula is like this for that range (that consists of 118 rows and 7 columns):
{IFERROR(HLOOKUP(Data!D371:D478;Data!B361:HU367;4;FALSKT);"NA")}
I then copy that range (where only 60 rows are non-blank and the rest of the rows are blank cells
) to the other range with:
=IF(ChosenData!B196="NA";"";ChosenData!B196)
and so on...
I then use the VBA to copy it over to an other sheet in my workbook:
Sub GetRet()
Worksheets("ChosenData").Select
Range("J195").CurrentRegion.Select
Selection.Copy
Worksheets("Analys").Select
Range("L10").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
End Sub
The sub above selects all the 118 rows but I only want to select only the rows until the row where at least one of the columns is non-blank
.
Last post suggested to use:
Lastrow = Evaluate("=MATCH("""",L10:L1000&M10:M1000&N10:N1000&O1:O1000&P10:P1000&Q10:Q1000&R10:R1000,0)")
But that solution select some randow row (which is non-blank
) !
Best Regards!
Does anyone have a suggestion?