C Board  

Go Back   C Board > General Programming Boards > C++ Programming

Reply
 
LinkBack Thread Tools Display Modes
Old 05-30-2003, 08:43 AM   #1
Registered User
 
Join Date: May 2003
Posts: 5
Simple C++ GUI programme does'nt run from dos

Actually I have made programme in C++ .The programme is using graphics functions. I want to Compile it from dos (cmd) using Tcc compiler. but when i compile it, it gives me linker errors about gui files. Although same programme Compiles correctly from C editor(IDE).

question is WHAT should I do ????????????.

I want to run it from Dos (its very essential)

tanx .

please answer as quickly as possible
Shadowhunt is offline   Reply With Quote
Old 05-30-2003, 09:44 AM   #2
Spanky
 
devour89's Avatar
 
Join Date: Nov 2002
Posts: 148
Are you linking the correct libs?
__________________
Dev C++
Win XP/2k/98

I DO NOT TAKE CLASSES I DONT GET HOMEWORK THIS IS NOT A HOMEWORK QUESTION!!!

He's lean he's keen... He's the spank machine!
devour89 is offline   Reply With Quote
Old 05-30-2003, 10:16 AM   #3
Carnivore ('-'v)
 
Hunter2's Avatar
 
Join Date: May 2002
Posts: 2,865
What graphics functions are you using? What are you using for graphics?
__________________
Just Google It. √

(\ /)
( . .)
c(")(") This is bunny. Copy and paste bunny into your signature to help him gain world domination.
Hunter2 is offline   Reply With Quote
Old 05-30-2003, 06:11 PM   #4
Hardware Engineer
 
Join Date: Sep 2001
Posts: 1,397
General comments...

I don't know if this will be of any help...

If you have C-Editor configured to invoke your Tcc compiler, then assuming everything is set-up properly, the results should be identical from the command line and the IDE.

There are Windows IDE compilers that can create DOS applications, and command line compilers (The free Borland compiler) that can make windows applications.

Not all compilers can make true-DOS applications. For example, Microsoft Visual C++ can make a console application that runs in a DOS-like window, but these applications will not run on a true-DOS machine.

Graphics are NOT part of the ISO/ANSI C++ standard. Every compiler has different graphics functions. You can't use the graphics library from one compiler in another compiler. See the FAQ There are 3rd party libraries that work with multiple compilers (OpenGL).

Finally, anybody who thinks any GUI application is simple probably doesn't need any help from me.
DougDbug is offline   Reply With Quote
Old 05-31-2003, 05:30 AM   #5
Registered Luser
 
Join Date: Apr 2003
Posts: 17
Re: Simple C++ GUI programme does'nt run from dos

Quote:
Originally posted by Shadowhunt
Actually I have made programme in C++ .The programme is using graphics functions. I want to Compile it from dos (cmd) using Tcc compiler. but when i compile it, it gives me linker errors about gui files. Although same programme Compiles correctly from C editor(IDE).

question is WHAT should I do ????????????.

I want to run it from Dos (its very essential)
From what I remember about Turbo C++ and its graphics, you need to copy those .BGI (Borland Graphics Interface) files to the same folder your .exe is present in. These files otherwise would be present in the BGI subfolder of your TC compiler.

Furthermore, if you are using Fonts provided by Borland, you need to copy those .CHR files to the executable folder too.

Basically, you have to specify the 'path' of the Graphic library files you'd be using. You can either specify this in the source itself (and put .BGI files in a different folder relative to the executable), or simply put the .BGI files in the same folder as executable.
eMMeMM is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Gui Programme does'nt Compiles from DOS Shadowhunt C++ Programming 1 06-06-2003 08:05 AM
Programs run in dos. Why not windows? marcusbankuti C++ Programming 15 08-11-2002 07:33 PM
Program to run in Dos only ihsir C++ Programming 2 01-19-2002 06:16 PM
DOS program versus DOS console program scromer A Brief History of Cprogramming.com 4 01-10-2002 01:42 PM
How to run DOS commands from c++ ihsir C++ Programming 2 12-05-2001 05:59 AM


All times are GMT -6. The time now is 02:48 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.0 RC2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22