Click here to Skip to main content
13,254,754 members (51,302 online)
Rate this:
Please Sign up or sign in to vote.
Hey guys, I just wanted to ask everyone on their opinion in which win form they think is best for a simple click-to-play game.

Its a 2-d game.

Should I use a 'Windows Form' or a 'User Control'?
What are the disadvantages and advantages of each?

Thank you.
Posted 23-Feb-13 21:33pm
Rate this: bad
Please Sign up or sign in to vote.

Solution 2

Form vs User Control:
- Form[^] is top level control used for program windows
- UserControl[^] is used to create other controls. We put this into Forms and other controls.
- both are derived from ContainerControl[^]

If you want to try develop “simple click-to-play 2-d game”, I recommend you to use WPF[^] instead of Windows Forms, although both are not designed for game development.
With WPF you can very easily achieve:
- styling of controls
- drawing on Canvas
- animations and transitions

XNA[^] is for game design.
vlad781 24-Feb-13 12:35pm
Thank you, very informative and easy to understand.
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

This isn't a question about what to use for a game, it's your homework question:
What are the disadvantages and advantages of a 'Windows Form' and a 'User Control'?

And we do not do your homework: it is set for a reason. It is there so that you think about what you have been told, and try to understand it. It is also there so that your tutor can identify areas where you are weak, and focus more attention on remedial action.

Try it yourself, you may find it is not as difficult as you think!
vlad781 24-Feb-13 2:55am
Its not my homework. I'm simply doing this as a hobby. I'm just trying to get some advice from a developers viewpoint.
OriginalGriff 24-Feb-13 3:24am
Then ask a question which makes sense.
The two are not equivalent; you can't use a form instead of a user control and vice versa. You use user controls on forms.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web04 | 2.8.171114.1 | Last Updated 24 Feb 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100