Ask and ye shall receive. Attached is the file to use. Code is unlocked. You can enter any matrix and it will find the number of non-zero rows. Since you are learning VB, I put comments in the code for you for each step of the way. Run-time is lightning fast. Be advised this does not solve the matrix, or reduce rows. If that is what you want, give me some more detail on what you want to do. You would need this code anyway if you want to take it further.

For those users who want to learn code, but don't know their way around vb, I'm pasting in the full code on this post:

Sub findrank()

' findrank macro recorded by Math Celebrity

' Declare variables

Dim a, b, i, j, rowtot, ranktot As Integer

' Error message to user if first cell not filled out for the matrix

If Len(Range("A1").Value) = 0 Then

MsgBox "You need to enter your first matrix value in Cell A1", vbExclamation, "Missing Information"

Range("A1").Select

Exit Sub

End If

' Start at the upper left corner of Excel for your matrix evaluation

' Find number of rows of the matrix

a = 1

Do While Len(Cells(a, 1)) > 0

a = a + 1

Loop

' Find number of columns of the matrix

b = 1

Do While Len(Cells(1, b)) > 0

b = b + 1

Loop

' Now loop through every column of each row, and check to see if all entries are zero

ranktot = 0

rowtot = 0

For i = 1 To a - 1

' reset row tot for each new row

rowtot = 0

For j = 1 To b - 1

If Cells(i, j).Value <> 0 Then rowtot = rowtot + 1

Next j

'For every row that has non-zero entries, increase rank by 1

If rowtot > 0 Then ranktot = ranktot + 1

Next i

' Message Box answer of rank to user

MsgBox "The rank of your " & i - 1 & " x " & j - 1 & " matrix = " & ranktot, vbInformation, "Matrix Rank"

End Sub