Hello
I try populating date automatically in column DATE based on entering adjacent textbox in column CODE . currently code populate for all of textboxes in column DATE even if the adjacent textboxes for the rest of rows in column code are empty .
so what I want to populate date in texbox into DATE column based on filling of adjacent textbox in CODE column for each row separately on userform . if the others rows contain empty adjacent textboxes , then should not populate date in DATE column for the same row based on adjacent textbox is empty then .
Sub pop_date()
Dim i, S As Long
For i = 67 To 130 Step 7
'first set of TextBoxes
If Me.Controls("TextBox" & i) <> "" Then
For S = 66 To 129 Step 7
With Me.Controls("TextBox" & S)
.Value = Format(Date, "dd/mm/yyyy")
End With
'second set of TExtBoxes
Next S
End If
Next i
End Sub
Private Sub TextBox67_AfterUpdate()
Call pop_date
End Sub
thanks