|
-
January 30th, 2008, 12:16 PM
#1
C++ newbie here... a stupid question needs answering
hi, im a newbie at c++, i just started learning functions and arguements.
sorry for asking such a stupid question but...
can u make a C++ program that is shown outside of the command prompt window?
thanks
ps: i admire all you guys and hope one day i rise to your level in programming
-
January 30th, 2008, 12:22 PM
#2
Re: C++ newbie here... a stupid question needs answering
As in a program that has a graphical user interface?
-
January 30th, 2008, 12:26 PM
#3
Re: C++ newbie here... a stupid question needs answering
Yes. All you need to do is access the Windows API from within your program.
If the program is designed as a windows program then it will automatically launch outside the command prompt after you type its name on the command line.
If it's a console program (runs inside and outputs text to the console window) you can still access the Windows API and create windows, etc. outside the command prompt window.
-
January 30th, 2008, 12:31 PM
#4
Re: C++ newbie here... a stupid question needs answering
umm windows api??
please elaborate on that or link some pages that explain it
thanks
-
January 30th, 2008, 12:47 PM
#5
Re: C++ newbie here... a stupid question needs answering
yea laser light, something like that
-
January 30th, 2008, 01:02 PM
#6
Re: C++ newbie here... a stupid question needs answering
The answer is obviously yes. 0xC0000005 has given you a pointer on how to go about it on Windows. That said, you should build up your fundamentals before tackling a GUI.
-
January 30th, 2008, 01:05 PM
#7
Re: C++ newbie here... a stupid question needs answering
thank you.. i will do that
-
January 30th, 2008, 01:05 PM
#8
Re: C++ newbie here... a stupid question needs answering
While using the Win32 API directly can get you some functionality, learning all the intricacies can be rather difficult. *If* you're looking to create a GUI program, I'd suggest using a GUI toolkit such as GTK.
-
January 30th, 2008, 01:06 PM
#9
Re: C++ newbie here... a stupid question needs answering
 Originally Posted by c0olGuY77
umm windows api??
please elaborate on that or link some pages that explain it
thanks
The Windows API (application programming interface) is simply a set of functions located in the Windows system dlls that are called by an application to do whatever a Windows program does.
The Windows API functions are analogous to the C standard runtime library functions that you may be familar with. For example, by including "windows.h" in your application you have the prototypes for the basic functions needed to create simple Windows programs (outside of the command prompt window) in much the same way that including "stdio.h" in a console program allows you to do basic i/o in the console window.
The Windows API is not some obscure interface that's difficult to locate. Just type "Windows API" into Google and you'll find plenty of information.
If you want to know how to do something specific, then ask here.
-
January 30th, 2008, 01:08 PM
#10
Re: C++ newbie here... a stupid question needs answering
thanks, ill keep learning now that i know its not just boring command prompt windows
-
January 30th, 2008, 01:12 PM
#11
Re: C++ newbie here... a stupid question needs answering
The particular method of IO----whether GUI or on the command line----is only one aspect of programming, and often the least important. Looking pretty is useless if your program doesn't do anything interesting.
That said, it can be rather neat to see visual results from your programs. That's why I took a Computer Graphics course and learned OpenGL.
-
January 30th, 2008, 01:26 PM
#12
Re: C++ newbie here... a stupid question needs answering
 Originally Posted by c0olGuY77
thanks, ill keep learning now that i know its not just boring command prompt windows
thats what i used to be like, then i learnt the win32 api and i hardly ever code it, theres really no point in it unless your coding a program for use by idiots
although it's a fun thing to do
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|