J
justme
How can I make the default value of the input box the same as the last user
input (duplicating the functionality of the built-in find/replace dialog)?
Dim iLastRow As Long
Dim i As Long
Dim LastInput As Long
With ActiveSheet
iLastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To iLastRow
Dim iLastRow As Long
Dim i As Long
With ActiveSheet
iLastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To iLastRow
If IsEmpty(Cells(i, "A")) And _
(Cells(i, "F").Value <> "" Or Cells(i, "J").Value <> "") Then
Cells(i, "A").Select
EnterFactory = InputBox("Enter Factory#: ")
If EnterFactory <> "" Then
Cells(i, "A").Value = EnterFactory
End If
End If
Next i
End With
MsgBox "No More Blank Factories"
End Sub
Thank you so much.
input (duplicating the functionality of the built-in find/replace dialog)?
Dim iLastRow As Long
Dim i As Long
Dim LastInput As Long
With ActiveSheet
iLastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To iLastRow
Dim iLastRow As Long
Dim i As Long
With ActiveSheet
iLastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To iLastRow
If IsEmpty(Cells(i, "A")) And _
(Cells(i, "F").Value <> "" Or Cells(i, "J").Value <> "") Then
Cells(i, "A").Select
EnterFactory = InputBox("Enter Factory#: ")
If EnterFactory <> "" Then
Cells(i, "A").Value = EnterFactory
End If
End If
Next i
End With
MsgBox "No More Blank Factories"
End Sub
Thank you so much.