i'm totally new with VBA and need your help, the problem is i want to select random cells in a given row, as you can see in the picture, the userform have ComboBox X = represent row, TextBox Y=Represent column and CommanButton "Input", i'm stuck with the error when i try to input multiple values separated with comma inside the textbox, as far it only works if the textbox contain a single values within, here is my code :
Private Sub cbInput_Click()
Dim x As Variant
Dim y As Variant
x = cmbBox_X.Value
y = txtBox_Y.Value
With Worksheets.Application.ActiveSheet
.Cells(x, y).Value = "check" '(error in here when i try with multiple values: runtime error ''13''; type mismatch)
End With
End Sub
Private Sub cbInput_Click()
Dim x As Variant
Dim y As Variant
x = cmbBox_X.Value
y = txtBox_Y.Value
With Worksheets.Application.ActiveSheet
.Cells(x, y).Value = "check" '(error in here when i try with multiple values: runtime error ''13''; type mismatch)
End With
End Sub