My goal is to code manually a userForm with Excel VBA (2018 MacOS version).
Being a beginner and confirming the unavailability of inserting userform in Excel 2018 MacOS, I have started by a simple VBA script example from : https://excelmacromastery.com/vba-user-forms-1/#A_Modal_Example
' PROCEDURE CODE
Sub UseModal()
' Create and show form
Dim frm As New UserFormFruit
' Display Userform - The code in this procedure
' will wait here until the form is closed
frm.Show
' Display the returned value
MsgBox "The user has selected " & frm.Fruit
' Close the form
Unload frm
Set frm = Nothing
End Sub
' USERFORM CODE
' Returns the textbox value to the calling procedure
Public Property Get Fruit() As Variant
Fruit = textboxFruit.Value
End Property
But I get "type used not defined".
Here a screenshot of my project interface :
I would like to know where is my error: how to define the type used?
(I am using Excel 2018 for MacOS).