jrflanagan
asked on
Combine specified column with user inputted row
How can I take a user inputted row to select a specific cell if the column is specified in the code?
I've got a userform with a TextBox for the user to enter the row number.
Say the column I am interested in is Column A...
If the user inputs "2".....I want to set the output cell to the value in A2
If the user inputs "43"......A43...etc.
Thank you!
I've got a userform with a TextBox for the user to enter the row number.
Say the column I am interested in is Column A...
If the user inputs "2".....I want to set the output cell to the value in A2
If the user inputs "43"......A43...etc.
Thank you!
ASKER
The user will be inputting the value in a userform.....so the value will be stored in sometihng like TextBox1.Value
How can i reference that value?
How can i reference that value?
Try code below:
Dim mRow As Long
Dim mColumn As Long
Dim mValue As String
mColumn = ActiveCell.Column
If IsNumeric(Me.TextBox1.Text) Then
mRow = Me.TextBox1.Text
mValue = Me.TextBox2.Text
Rows(mRow).Columns(mColumn).Value = mValue
End If
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
That did it, thank you!
=CONCATENATE("A",A1) where A1 is where the user enters the number