jump to cell

raj_tomerin

New Member
Joined
Oct 1, 2011
Messages
7
I have two columns A and B. Suppose i write 3 in Cell A1, then I want 3 goes to B3. in the same way if i write 5 in cll A2 then i want 5 goes to B5.
So my problem is that whatever i write in any cell of column A (i.e. cell value. from 1 to 100) that value must go to the respective cell in column B ( i.e. B1 to B100). Is there any solution or macro for it. Please help
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Hi Raj,

Right-click on the worksheet tab name, click on View Code and paste in the following (this relies on the Worksheet Change event as explained here - http://www.ozgrid.com/VBA/run-macros-change.htm):

Code:
Private Sub Worksheet_Change(ByVal Target As Range)

If Not Intersect(Target, Range("A1:A100")) Is Nothing Then
    Range("B" & Target.Row) = Target
End If

End Sub
Is there a reason you need code to do this rather than just having the formula: =A1 in cell B1 and dragged down to B100?
 
Upvote 0

Forum statistics

Threads
1,224,609
Messages
6,179,874
Members
452,949
Latest member
Dupuhini

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