Finding first blank row, then writing to it

后端 未结 8 1880
小鲜肉
小鲜肉 2020-12-02 00:30

I need to find the first blank row in a workbook and write information to (row, 1) and (row, 2). I think I\'m currently pretty stuck...

Function WriteToMaste         


        
8条回答
  •  执笔经年
    2020-12-02 00:42

    Function firstBlankRow() As Long
    Dim emptyCells As Boolean

        For Each rowinC In Sheet7.Range("A" & currentEmptyRow & ":A5000")   ' (row,col)
    
            If rowinC.Value = "" Then
                currentEmptyRow = rowinC.row
                'firstBlankRow = rowinC.row 'define class variable to simplify computing complexity for other functions i.e. no need to call function again
                Exit Function   
            End If
        Next
    

    End Function

提交回复
热议问题