Hi Guys
I have this code that when you click a shape a user form will pop up then when you close the user form another shape will appear. I want to repeat this process until the last shape appear. I cant upload the excel file, here's the code that I used I'm Stocked to the second shape.
copy to clipboard
Sub Oval1_Click()
List = 1
UserForm1.TextBox1.Text = Application.WorksheetFunction.VLookup(List, Sheet1.Range("b3:c7"), 2, False)
UserForm1.Show
End Sub
Sub Oval2_Click()
List = 2
UserForm1.TextBox1.Text = Application.WorksheetFunction.VLookup(List, Sheet1.Range("b3:c7"), 2, False)
UserForm1.Show
End Sub
the user form code which I want to repeat
copy to clipboard
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
If CloseMode = 0 Then
ActiveSheet.Shapes("Oval 5").Visible = True
End If
End Sub
I have this code that when you click a shape a user form will pop up then when you close the user form another shape will appear. I want to repeat this process until the last shape appear. I cant upload the excel file, here's the code that I used I'm Stocked to the second shape.
copy to clipboard
Sub Oval1_Click()
List = 1
UserForm1.TextBox1.Text = Application.WorksheetFunction.VLookup(List, Sheet1.Range("b3:c7"), 2, False)
UserForm1.Show
End Sub
Sub Oval2_Click()
List = 2
UserForm1.TextBox1.Text = Application.WorksheetFunction.VLookup(List, Sheet1.Range("b3:c7"), 2, False)
UserForm1.Show
End Sub
the user form code which I want to repeat
copy to clipboard
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
If CloseMode = 0 Then
ActiveSheet.Shapes("Oval 5").Visible = True
End If
End Sub