Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Skute

Dialog App?

This topic is 5687 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, im trying to create a dialog application but i cant find anywhere on the web with a tutorial about it that isnt MFC!! *grumble damn MFC* Anyway, how do i get the WinMain function to startup a dialog box (already designed in resources)? Thanks

Share this post


Link to post
Share on other sites
Advertisement
yeah i got it now thanks

msdn annoys me sometimes cause its always full of rubbish mfc!


int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
{
return DialogBox(hInstance, MAKEINTRESOURCE(IDD_MAIN), NULL, DlgProc);
}

BOOL CALLBACK DlgProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
{
switch(Message)
{

etc
etc

Thanks

Share this post


Link to post
Share on other sites
just a note
these fucking prejudices against MFC are fucking bullshit

i thought the same way
then someone i know pointer me to the 3d app article on this page and i got the hang of MFC within 3-4 days by playing around and examine the code


1. use the class wizzard you don t have to remember all these ugly macros

2. www.codeproject.com excellent MFC tuts and advance controls

3. stop bitch about MFC when you have never tried it

Share this post


Link to post
Share on other sites
i have tried it actually

did a whole module on it at university, i much prefer to write the code out by hand.

in the end i find it makes alot more sense because its all written by you.

but ill check the tuts out anyways, thanks

Share this post


Link to post
Share on other sites
quote:
Original post by Basiror
just a note
these fucking prejudices against MFC are fucking bullshit



Hmm... I'm sure everyone around here is dying to listen to the opinion of someone as intellectual as yourself...

Just because someone dislikes a certain paradigm or way of coding doesn't mean they are attacking it, and as you found out, sometimes they ARE speaking from experience, so don't be so quick to blow up.





"With my feet upon the ground I lose myself between the sounds and open wide to suck it in, I feel it move across my skin. I'm reaching up and reaching out. I'm reaching for the random or what ever will bewilder me, what ever will bewilder me. And following our will and wind we may just go where no one's been. We'll ride the spiral to the end and may just go where no one's been." - Maynard James Keenan
Name: TheBlackJester
Team: Wildfire Games

Projects
O A.D.
The Last Alliance


[edited by - TheBlackJester on January 23, 2003 7:01:43 PM]

Share this post


Link to post
Share on other sites
quote:
Original post by Skute
msdn annoys me sometimes cause its always full of rubbish mfc!


this statement doesn't look like one made by experienced person. most of the time, people who speak this way about mfc have never tried it or never took the time to learn it properly or at all, and are talking out of their ass.

sure, mfc is not perfect, and i don't use it much anymore, but these flame-smelling comments coming from people with little to no knowledge of mfc are very annoying.

[edited by - niyaw on January 23, 2003 8:01:17 PM]

Share this post


Link to post
Share on other sites
reason i wrote that is because i''d been up for hours searching of a non-mfc way of writing that code....

took me ages until i remembered a site i used to visit, not even my petzold books told you howto do it, they showed howto create a dialog in your main app, but they didnt show howto make your main app a dialog.


For university i had to create an icon application (one which could create, save, edit, open a .ico file) and use different paint tools with it. Tbh, worst coding experience of my life. That is the reason for my dislike against MFC.

Never mind, thanks for the comments all.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!