06-13-2022, 10:08 AM
When I try to compile this snippet
I get the following error:
------------------------
Expected )
Caused by (or after):
Line 9:
Function Button_New(x As Integer, y As Integer, w As Integer, h As Integer, Text As String) As Button
------------------------
Can someone clarify what I am doing wrong.
Code: (Select All)
Type ButtonT
x As Integer 'Position left top
y As Integer
w As Integer 'Height
h As Integer 'Width
text As String 'label
End Type
Function Button(x As Integer, y As Integer, w As Integer, h As Integer, Text As String) As ButtonT
'Defines and draws a new button
Dim As ButtonT btn
btn.x = x
btn.y = y
btn.h = h
btn.w = w
btn.text = text
'Button_Draw(btn, ButtonColor)
Return btn
End Function
------------------------
Expected )
Caused by (or after):
Line 9:
Function Button_New(x As Integer, y As Integer, w As Integer, h As Integer, Text As String) As Button
------------------------
Can someone clarify what I am doing wrong.