for this line:
Private _allowedLocations As Point() = New () {New Point(50, 50), New Point(500, 500), New Point(700, 100)
i am getting the error "type expected for 'new ()'
whats wrong with the syntax?
for this line:
Private _allowedLocations As Point() = New () {New Point(50, 50), New Point(500, 500), New Point(700, 100)
i am getting the error "type expected for 'new ()'
whats wrong with the syntax?
You need to repeat the type name before the (). You can rewrite the code as follows
Private _allowedLocations As Point() = New Point() {New Point(50, 50), New Point(500, 500), New Point(700, 100) }
I thought the whole New-expression was unnecessary:
Private _allowedLocations As Point() = {New Point(50, 50), New Point(500, 500), New Point(700, 100) }