Visual C++

Moderators: Lundin
Number of threads: 373
Number of posts: 687

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
VC++ help in a simple progam Posted by rahulm87 on 19 Jan 2009 at 10:32 AM
hi
I just wrote a simple program to show a message box in vc++ it compiled without any error but showed 2 errors while building .....as am new to vc++ i couldn't solve it ....need help pls

Program is

#include<windows.h>
int _stdcall WinMain(HINSTANCE hInstance,HINSTANCE hPervInstance,LPSTR lpszCmdline,int nCmdShow)
{
MessageBox(0,"Hello","Hello title",0);
return(0);
}


Error's are as shown below

unresolvable external symbol _main
1 external externals

thank u
rahul
Report
Re: VC++ help in a simple progam Posted by santoshmp on 3 Feb 2009 at 2:24 AM
Looks like you created a console application.
Create a Windows application and put this code in there.
Report
Re: VC++ help in a simple progam Posted by rahulm_787 on 11 Feb 2009 at 7:50 AM
thank u ...i will try creating window application



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.