Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Sep 6th, 2006, 4:55 PM   #1
Edgar
Programmer
 
Edgar's Avatar
 
Join Date: May 2006
Location: Bathroom
Posts: 43
Rep Power: 0 Edgar is on a distinguished road
Progwin 32 is not working

Hi, Im traying to get this done but is not working, this is what i'm doing:

#include <windows.h>

int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
     LPSTR lpCmdline, int nCmdshow)
{
  MessageBox(NULL, "Goddbye, cuel world!", "Note", MB_OK);
  return 0;
}

and this is the error massage that I have:

C:\cwork>dmc test.c
Fatal error: unable to open input file 'win16\WINDOWS.H'
--- errorlevel 1

I'm using a c compiler (DMC )
thanks for your halep.
Edgar is offline   Reply With Quote
Old Sep 6th, 2006, 5:10 PM   #2
_James_
Newbie
 
Join Date: Sep 2006
Location: UK
Posts: 20
Rep Power: 0 _James_ is an unknown quantity at this point
Maybe its because your compiler paths or not set up correctly or that the file windows.h is not actually there.

I have not used the Digital Mars C compiler so i cant say exacly how to set the compiler environment paths. If you are having issues with this compiler then there is LCC which is a good C compiler and MinGW which is a port of GCC for windows.
_James_ is offline   Reply With Quote
Old Sep 6th, 2006, 5:14 PM   #3
Edgar
Programmer
 
Edgar's Avatar
 
Join Date: May 2006
Location: Bathroom
Posts: 43
Rep Power: 0 Edgar is on a distinguished road
Do you thing that borland is gonna work without any modifications?
Edgar is offline   Reply With Quote
Old Sep 6th, 2006, 5:21 PM   #4
_James_
Newbie
 
Join Date: Sep 2006
Location: UK
Posts: 20
Rep Power: 0 _James_ is an unknown quantity at this point
Which one?

There is borland C++ 5.5 which is old. Its requires you to make some configuration files for it to work but thats not hard. There is also Turbo C++ which they just released. I have not tried Turbo C++ but I have doubts that Borland can get back to the glory days based from the recent stuff they have made. They should both compile Win32 programs. If you are looking for an easy to use C compiler for Win32 development then LCC is good as you just have to run a simple installer and there is even a good text editor and debugger included.

You could also download Visual C++ 2005 Express and then the Platform SDK. This would take over 1GB of downloading and you still need to follow a simple guilde to get VC++ Express to compile Win32 apps.
_James_ is offline   Reply With Quote
Old Sep 6th, 2006, 6:44 PM   #5
Prm753
Professional Programmer
 
Prm753's Avatar
 
Join Date: Oct 2005
Location: United States
Posts: 447
Rep Power: 4 Prm753 is on a distinguished road
Send a message via AIM to Prm753 Send a message via MSN to Prm753
Well, did you read your error "massage"? It simply states that it cannot find Windows.h. Perhaps searching for that file yourself might be in order.
__________________
The world's first athletic computer geek!
The home of PrProgramsStudios
How not to post a question: <-- Please don't reply
Prm753 is offline   Reply With Quote
Old Sep 6th, 2006, 7:05 PM   #6
Edgar
Programmer
 
Edgar's Avatar
 
Join Date: May 2006
Location: Bathroom
Posts: 43
Rep Power: 0 Edgar is on a distinguished road
How I'll search for that?
Edgar is offline   Reply With Quote
Old Sep 6th, 2006, 7:25 PM   #7
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
You could try the Windows search tool. It's not just there to look pretty.
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Old Sep 7th, 2006, 1:27 PM   #8
Edgar
Programmer
 
Edgar's Avatar
 
Join Date: May 2006
Location: Bathroom
Posts: 43
Rep Power: 0 Edgar is on a distinguished road
and then what?
Edgar is offline   Reply With Quote
Old Sep 7th, 2006, 4:54 PM   #9
Prm753
Professional Programmer
 
Prm753's Avatar
 
Join Date: Oct 2005
Location: United States
Posts: 447
Rep Power: 4 Prm753 is on a distinguished road
Send a message via AIM to Prm753 Send a message via MSN to Prm753
*rips at hair* And then, if Windows can find the file named 'Windows.h', put it into your 'win16' folder. Or, you can modify the compiler options to look for Windows.h somewhere other than 'win16'.
__________________
The world's first athletic computer geek!
The home of PrProgramsStudios
How not to post a question: <-- Please don't reply
Prm753 is offline   Reply With Quote
Old Sep 7th, 2006, 5:20 PM   #10
_James_
Newbie
 
Join Date: Sep 2006
Location: UK
Posts: 20
Rep Power: 0 _James_ is an unknown quantity at this point
I have done some research(good old google) and I noticed that the Digital Mars C/C++ compiler is not exacly modern. Its not even designed to run after the 31st December 1999. It even warns you about that in the license agreement! I think you should think about looking at using another compiler.

If you are just doing C programming then LCC is very good. There is also MinGW(port of GCC for windows) which is also useful. I know its not really the solution you are looking for. I dont think any one so far in this thread has actually used the compiler you are using so help has been a bit of shooting in the dark.
_James_ is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
working example badbasser98 C++ 16 Mar 31st, 2006 9:29 AM
Reading and writing files not working under Windows (find under unix/linux) .TD Java 2 Mar 30th, 2006 12:42 PM
working with xml and c# and get this error dark_omen C# 4 May 6th, 2005 6:55 AM
JSP not working on the live server Braveheart Java 0 Mar 9th, 2005 8:20 PM
Flash Actionscript - Why isnt my 'for' loop working? TerraNerd Other Scripting Languages 2 Feb 26th, 2005 10:30 PM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 2:10 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC