johannordgren
New Member
- Joined
- Apr 24, 2018
- Messages
- 31
As the title says, my need is to copy a made command button to another 500 rows.
The code I'm using is this;
Private Sub CommandButton1_Click()
Dim x As Integer
x = Range("A1").Value
Range("A1").Value = x + 1
End Sub
Which makes a count of how many times the button is clicked.
What i would like is to copy this button, pretty much like you would copa down a normal excel cell. I'm talking about the "draging down".
Essentialy i would like the cells in the formula above (A1) to automaticly change, or if you are smarter than me, which you probably are, make a completely different code.
I dont even know if this is possible, but if it is, please help!
The code I'm using is this;
Private Sub CommandButton1_Click()
Dim x As Integer
x = Range("A1").Value
Range("A1").Value = x + 1
End Sub
Which makes a count of how many times the button is clicked.
What i would like is to copy this button, pretty much like you would copa down a normal excel cell. I'm talking about the "draging down".
Essentialy i would like the cells in the formula above (A1) to automaticly change, or if you are smarter than me, which you probably are, make a completely different code.
I dont even know if this is possible, but if it is, please help!