| | |
Expanind DoS Window
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
Hey, I have been searching this for a while now, and I cannot find a c++ code that expands the window once opened. I have found multiple codes that claim it opens it in an expanded window, but in the end all I get is compiling errors.
If someone would be so kind as to give a full example code that will open the window in a larger format, it would be greatly appreciated.
Note: I am using Visual Studios Express Edition, not sure if it matters or not..
Edit: I just realized how retarded my typo was on the header. It's supposed to be 'expanded'. Sorry..I'm tired.
If someone would be so kind as to give a full example code that will open the window in a larger format, it would be greatly appreciated.
Note: I am using Visual Studios Express Edition, not sure if it matters or not..
Edit: I just realized how retarded my typo was on the header. It's supposed to be 'expanded'. Sorry..I'm tired.
Last edited by restrictment; 33 Days Ago at 1:43 am.
1
#2 33 Days Ago
This guy can do some amazing stuff with the DOS console window.. best tutorial I've seen for become a master of the console:
http://www.adrianxw.dk/index.html
I think you'd be interested in, "Win32 Console Applications - Part 6"
http://www.adrianxw.dk/SoftwareSite/...Consoles6.html
http://www.adrianxw.dk/index.html
I think you'd be interested in, "Win32 Console Applications - Part 6"
http://www.adrianxw.dk/SoftwareSite/...Consoles6.html
Last edited by Clinton Portis; 33 Days Ago at 1:58 am.
0
#3 33 Days Ago
•
•
•
•
This guy can do some amazing stuff with the DOS console window.. best tutorial I've seen for become a master of the console:
http://www.adrianxw.dk/index.html
I think you'd be interested in, "Win32 Console Applications - Part 6"
http://www.adrianxw.dk/SoftwareSite/...Consoles6.html
However, it didn't really show me how to start it in full screen. I am really new to C++, so maybe I missed something..
-7
#5 33 Days Ago
try this: compiled with vc++ 2008 express
C++ Syntax (Toggle Plain Text)
#include <windows.h> #include <iostream> using std::cin; int main() { HWND hWnd = GetConsoleWindow(); ShowWindow(hWnd,SW_MAXIMIZE); cin.get(); return 0; }
Don't PM me with questions -- you might get a nasty PM in response. If you have a question then post it in one of the forums.
0
#6 33 Days Ago
•
•
•
•
try this: compiled with vc++ 2008 express
C++ Syntax (Toggle Plain Text)
#include <windows.h> #include <iostream> using std::cin; int main() { HWND hWnd = GetConsoleWindow(); ShowWindow(hWnd,SW_MAXIMIZE); cin.get(); return 0; }

C++ Syntax (Toggle Plain Text)
1>conversation.obj : error LNK2028: unresolved token (0A0002BF) "extern "C" int __stdcall ShowWindow(struct HWND__ *,int)" (?ShowWindow@@$$J18YGHPAUHWND__@@H@Z) referenced in function "int __cdecl main(void)" (?main@@$$HYAHXZ) 1>conversation.obj : error LNK2019: unresolved external symbol "extern "C" int __stdcall ShowWindow(struct HWND__ *,int)" (?ShowWindow@@$$J18YGHPAUHWND__@@H@Z) referenced in function "int __cdecl main(void)" (?main@@$$HYAHXZ) 1>C:\Users\Jake\Documents\Visual Studio 2008\Projects\test\Debug\test.exe : fatal error LNK1120: 2 unresolved externals 1>Build log was saved at "file://c:\Users\Jake\Documents\Visual Studio 2008\Projects\test\test\Debug\BuildLog.htm" 1>test - 3 error(s), 0 warning(s)
0
#7 32 Days Ago
It worked with me..
c++ Syntax (Toggle Plain Text)
#include <windows.h> #include <iostream> //maybe you should add this #pragma comment(lib,"kernel32.lib") #pragma comment(lib,"user32.lib") // this will puts a lib-search record in the object file using std::cin; int main() { HWND hWnd = GetConsoleWindow(); ShowWindow(hWnd,SW_MAXIMIZE); cin.get(); return 0; }
Last edited by cikara21; 32 Days Ago at 5:16 pm.
0
#8 32 Days Ago
•
•
•
•
It worked with me..
c++ Syntax (Toggle Plain Text)
#include <windows.h> #include <iostream> //maybe you should add this #pragma comment(lib,"kernel32.lib") #pragma comment(lib,"user32.lib") // this will puts a lib-search record in the object file using std::cin; int main() { HWND hWnd = GetConsoleWindow(); ShowWindow(hWnd,SW_MAXIMIZE); cin.get(); return 0; }
![]() |
Similar Threads
- Hidding the dos window (C++)
- Hiding dos window (C++)
- Keeping DOS window open in Devc++ (C++)
- The DOS window after compilation (C++)
- DOS automatically closes (Windows NT / 2000 / XP)
Other Threads in the C++ Forum
- Previous Thread: "Requesting" a url without opening a browser
- Next Thread: Very simple array program (but with a minor glitch)
| Thread Tools | Search this Thread |
api array based binary c++ c/c++ calculator char char* class classes code coding compile console conversion count database delete deploy desktop developer directshow dll download dynamic dynamiccharacterarray email encryption error file forms fstream function functions game givemetehcodez google graph gui homeworkhelp iamthwee ifstream input int integer java lib linkedlist linker linux list loop looping loops map math matrix memory multiple news number numbertoword output parameter pointer problem program programming project python random read recursion recursive reference return rpg sorting string strings struct temperature template templates test text text-file tree unix url variable vector video visualstudio win32 windows winsock wordfrequency wxwidgets






