Sign in to follow this  
ender_341

Polygon() C++(WIN32)

Recommended Posts

POINT points[3]; points[0] = { 5, 5 }; points[1] = { 55, 5 }; points[0] = { 55, 55 }; Polygon(hDC, points, 3); When i use this code i get a bunch of errors about missing {'s, }'s, and ;'s in that code block,Does anyone know whats wrong with it?

Share this post


Link to post
Share on other sites
Initialization using curly braces ({ and }) has to be done on the line that you define the variable.

POINT points[3] = { {5, 5}, {55, 5}, {55, 55} }; should work fine.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this