Here is the code in text form in case the image is not loading:
Sub CommandButton1_Click()
Dim NoIO As String
Dim shp1 As Visio.Shape
NoIO = ComboBox1.Value
If NoIO = "7" Then
MsgBox shp1.ID
'Call test(shp1)'
'Target shape id selected'
'Change shape data of that shape'
End If
Unload Me
End Sub
Whenever I try to output the ID of a shape, I get the error:
Object variable or With block variable not set
I cannot change the parameters of the subroutine as I get a procedure declaration mismatch since this code runs after a button click on a user form.