Alphacsulb
Active Member
- Joined
- Mar 20, 2008
- Messages
- 414
TextBox1 in my userform is a row I input a number into.
I'm having a problem identifying it as a range though. Here is my code:
Second question is, what is it called when you reference the "MrRowNumber" like I did here?
I'm having a problem identifying it as a range though. Here is my code:
Code:
Private Sub CommandButton1_Click()
MyRowNumber = TextBox1.Value
[COLOR=Red]'Here is where the problem starts, it says compile error, syntax error[/COLOR]
Range("DU" & MyRowNumber:"IC" & MyRowNumber).Select
Range("IC" & MyRowNumber).Activate
Selection.ClearContents
'This reference here works
TextBox2.Text = Range("IB" & MyRowNumber).Value
End Sub