Fill column cells as I enter into one box

Starfleet007

New Member
Joined
Nov 9, 2023
Messages
2
Office Version
  1. 365
Platform
  1. Windows
I want to fill the cells below from one box/cell I enter into. I type in box A1, press enter, and it fills A2. I then type in box A1 again, press enter, and it fills A3. The plan is to scan barcodes to fill into a column for comparative processes. THANKS!
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Hi and Welcome to the MrExcel forum. Please accept my warmest greetings and sincere hope that all is well.

Put the following code in the sheet events.

VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
  If Target.Address = "$A$1" Then
    If Target.Count > 1 Then Exit Sub
    If Target.Value = "" Then Exit Sub
    Range("A" & Rows.Count).End(3)(2).Value = Target.Value
    Target.Select
  End If
End Sub

Note Sheer Event:
Right click the tab of the sheet you want this to work, select view code and paste the code into the window that opens up.


----- --
Let me know the result and I'll get back to you as soon as I can.
Sincerely
Dante Amor
----- --
 
Upvote 1
Solution
Hi and Welcome to the MrExcel forum. Please accept my warmest greetings and sincere hope that all is well.

Put the following code in the sheet events.

VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
  If Target.Address = "$A$1" Then
    If Target.Count > 1 Then Exit Sub
    If Target.Value = "" Then Exit Sub
    Range("A" & Rows.Count).End(3)(2).Value = Target.Value
    Target.Select
  End If
End Sub

Note Sheer Event:
Right click the tab of the sheet you want this to work, select view code and paste the code into the window that opens up.


----- --
Let me know the result and I'll get back to you as soon as I can.
Sincerely
Dante Amor
----- --
THANKS!! This worked great!
 
Upvote 0

Forum statistics

Threads
1,215,262
Messages
6,123,935
Members
449,134
Latest member
NickWBA

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top