dev-cpp-users Mailing List for Dev-C++ (Page 474)
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
You can subscribe to this list here.
| 2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(15) |
Oct
(115) |
Nov
(154) |
Dec
(258) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2001 |
Jan
(377) |
Feb
(260) |
Mar
(249) |
Apr
(188) |
May
(152) |
Jun
(150) |
Jul
(195) |
Aug
(202) |
Sep
(200) |
Oct
(286) |
Nov
(242) |
Dec
(165) |
| 2002 |
Jan
(245) |
Feb
(241) |
Mar
(239) |
Apr
(346) |
May
(406) |
Jun
(369) |
Jul
(418) |
Aug
(357) |
Sep
(362) |
Oct
(597) |
Nov
(455) |
Dec
(344) |
| 2003 |
Jan
(446) |
Feb
(397) |
Mar
(515) |
Apr
(524) |
May
(377) |
Jun
(387) |
Jul
(532) |
Aug
(364) |
Sep
(294) |
Oct
(352) |
Nov
(295) |
Dec
(327) |
| 2004 |
Jan
(416) |
Feb
(318) |
Mar
(324) |
Apr
(249) |
May
(259) |
Jun
(218) |
Jul
(212) |
Aug
(259) |
Sep
(158) |
Oct
(162) |
Nov
(214) |
Dec
(169) |
| 2005 |
Jan
(111) |
Feb
(165) |
Mar
(199) |
Apr
(147) |
May
(131) |
Jun
(163) |
Jul
(235) |
Aug
(136) |
Sep
(84) |
Oct
(88) |
Nov
(113) |
Dec
(100) |
| 2006 |
Jan
(85) |
Feb
(119) |
Mar
(33) |
Apr
(31) |
May
(56) |
Jun
(68) |
Jul
(18) |
Aug
(62) |
Sep
(33) |
Oct
(55) |
Nov
(19) |
Dec
(40) |
| 2007 |
Jan
(22) |
Feb
(49) |
Mar
(34) |
Apr
(51) |
May
(66) |
Jun
(43) |
Jul
(116) |
Aug
(57) |
Sep
(70) |
Oct
(69) |
Nov
(97) |
Dec
(86) |
| 2008 |
Jan
(32) |
Feb
(47) |
Mar
(106) |
Apr
(67) |
May
(28) |
Jun
(39) |
Jul
(31) |
Aug
(25) |
Sep
(18) |
Oct
(25) |
Nov
(5) |
Dec
(21) |
| 2009 |
Jan
(33) |
Feb
(27) |
Mar
(27) |
Apr
(22) |
May
(22) |
Jun
(10) |
Jul
(17) |
Aug
(9) |
Sep
(21) |
Oct
(13) |
Nov
(4) |
Dec
(11) |
| 2010 |
Jan
(10) |
Feb
(8) |
Mar
(4) |
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(8) |
Oct
(26) |
Nov
(9) |
Dec
(1) |
| 2011 |
Jan
(21) |
Feb
(16) |
Mar
(4) |
Apr
(19) |
May
(26) |
Jun
(9) |
Jul
(6) |
Aug
|
Sep
(4) |
Oct
(3) |
Nov
(2) |
Dec
(1) |
| 2012 |
Jan
(4) |
Feb
(7) |
Mar
(4) |
Apr
|
May
(1) |
Jun
(10) |
Jul
(1) |
Aug
(1) |
Sep
(18) |
Oct
(3) |
Nov
(1) |
Dec
(1) |
| 2013 |
Jan
(4) |
Feb
(2) |
Mar
(15) |
Apr
(6) |
May
(1) |
Jun
(3) |
Jul
(1) |
Aug
(2) |
Sep
(4) |
Oct
|
Nov
(9) |
Dec
|
| 2014 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
(4) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(4) |
| 2015 |
Jan
(2) |
Feb
(3) |
Mar
(1) |
Apr
(2) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
(9) |
Nov
(35) |
Dec
(6) |
| 2016 |
Jan
(7) |
Feb
(10) |
Mar
(10) |
Apr
(9) |
May
(13) |
Jun
(9) |
Jul
(1) |
Aug
(3) |
Sep
(3) |
Oct
(1) |
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2019 |
Jan
(1) |
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Luc Saint-E. <lu...@re...> - 2002-12-06 23:24:07
|
Lahsen, Its an install problem.. here (4.9.7.0) it compile without problem. Luc At 23:34 06/12/2002 +0100, Lahsen BAALI wrote: > Hello, > The folowing code compile and run well with dev-cpp 4.9.6 |
|
From: Zachary U. <ne...@st...> - 2002-12-06 22:37:34
|
I installed the full Dev-C++ 4.9.60 package and then used the Update
facility to upgrade to Dev-C++ 4.9.7.0. I have the Win32 build with the
Mingw compiler (g++).
My problem is that the compiler doesn't seem to be able to find all my
source files or it is building in some other directory. Here is the steps I
took for this project:
C:\Dev-Cpp is root directory where Dev-C++ is installed
I clicked File-> New-> Project.
It brought up the "New project" dialog box .
Under Basic I selected Console Application
Under Project options I selected entered graph-adj for Name and selected
C++ Project.
Then it brought up the "Create new project" dialog box.
For File name I entered "C:\Dev-cpp\graph-adj.dev".
Then it brought up the Project window. So it listed Project: graph-adj and
had a main.cpp default file in there. I removed that file and
then I clicked "Add to Project" and selected the following files to add to
my project:
graph-adj.cpp, graph-adj.h, & main.cpp
These files I had earlier copied into the directory C:\Dev-cpp.
I also copied matrix.h and graph.txt which my graph-adj program uses into
this directory.
I went to the Execute menu and selected Compile.
It compiles and I get the following 5 errors:
Compiler: Default compiler
Building Makefile: "C:\Dev-Cpp\Makefile.win"
Executing make...
make.exe -f "C:\Dev-Cpp\Makefile.win" all
g++.exe -c main.cpp -o main.o -I"C:/DEV-CPP/include" -I"C:/DEV-CPP/include"
In file included from graph-adj.h:12,
from main.cpp:9:
matrix.h: In method `Matrix<Type>::Matrix(int, int, const Type &)':
matrix.h:76: parse error before `)'
g++.exe -c graph-adj.cpp -o graph-adj.o
-I"C:/DEV-CPP/include" -I"C:/DEV-CPP/include"
In file included from graph-adj.h:12,
from graph-adj.cpp:8:
matrix.h: In method `Matrix<Type>::Matrix(int, int, const Type &)':
matrix.h:76: parse error before `)'
g++.exe main.o graph-adj.o -o "graph-adj.exe"
-L"C:/DEV-CPP/lib" -I"C:/DEV-CPP/include" -I"C:/DEV-CPP/include"
G__~1.EXE: main.o: No such file or directory
G__~1.EXE: graph-adj.o: No such file or directory
G__~1.EXE: No input files
Execution terminated
The first error: "In file included from graph-adj.h:12," points to the
statement:
#include "matrix.h"
The second error: "In file included from main.cpp:9:" points to the statement:
#include "graph-adj.h"
Both these errors appear twice.
The fifth error "In method `Matrix<Type>::Matrix(int, int, const Type &)':"
is I believe
because for some reason the compiler cannot find the header file matrix.h
where this Matrix class
is defined.
ALso notice the compiler says it cannot find main.o, graph-adj.o or any
input files.
So what is the procedure for compiling a new project and how do I tell it
where my source files
are and where to build them?
Ideally I want the project to be in some other directory such as
C:\c++\projects\graph-adj\
BTW this same code compiled fine in Linux using g++ from command line. I
also tried adding matrix.h to my Dev-C++ Project window but I still get the
same errors.
Regards,
Zach
Zachary Uram
John 3:16
<><
|
|
From: Lahsen B. <la...@ti...> - 2002-12-06 22:32:25
|
Hello,
The folowing code compile and run well with dev-cpp 4.9.6
// essai.h file
#ifndef Essai_H
#define Essai_H
#include <vector>
using namespace std;
template<typename U> class InOut
{
private:
void cinCoutStream()
{
vector<U> vt;
copy(istream_iterator<U>(cin),
istream_iterator<U>(),
back_inserter(vt));
copy(vt.begin(),
vt.end(),
ostream_iterator<U>(cout, "\t"));
cout << endl;
}
public:
InOut(){}
~InOut(){}
void operator()()
{
cinCoutStream();
}
};
#endif //Essai_H
____________________________________________________________________________
_____________
// main.cpp file
#include <iostream>
#include <stdlib.h>
#include "essai.h"
int main(int argc, char *argv[])
{
InOut<char> cInOut;
cInOut();
system("PAUSE");
return 0;
}
____________________________________________________________________________
_____________
I have this message: " In member function 'void InOut<U>::cinCoutStream()':
line 18: parseerror befor ';' token
|
|
From: Lahsen B. <la...@ti...> - 2002-12-06 21:42:35
|
Hello, I try dev-cpp 4.9.7 with a default project console application without add any code c++. I have message: "In file included from main.cpp:1:c:/Dev-cpp/include/c++/iostream:44:28:bits/c++config.h: No such file or directory" ???????????????????????????????????????????!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!! ;-))))))) I find file c++config.h but in c:/Dev-cpp/include/c++/mingw32/bits ;-)))!!!! How get all right for dev-cpp 4.9.7? Thuks for your help :-) |
|
From: <or...@vp...> - 2002-12-06 19:25:06
|
Hi again!
I forgot to tell, that the declaration works for any kind of block.
E.g. these is also valid:
if {
int i;
//...
}
and others...
Hope I could help.
--
Best regards
OROSZI Balázs
|
|
From: <we...@ha...> - 2002-12-06 19:04:21
|
Hi Guys, I need implement in my code a funciont that copy a directory recursively (the directory and subdirectory) but only the updated files. Someone know how to do it ?? ps.: I use always FileCopy() but it didn't copy updated files only i think... :/ Thkz a lot... Best Regards.. [ ]'s |
|
From: <cg...@wo...> - 2002-12-06 19:01:52
|
If you do if (isdigit(buffer[i])) and you are reading the number
-152.1548042 it will lead you to say that number is 152, or that you
have two numbers, 152 and 1548042. Just something unconsistent.
Fortunatley it has no difficulty at all work with things this way.
But if you store that into a string char *buffer and you do
strtod(buffer, &characterpointer) it will return -152.155, once
corrected the other thing. Some function for maintain all the
precision?. I thought that double would maintain more precision than
plain float, but it's just the same. Using setprecision to greater
number, of course.
With a little file I send as example it takse more digits, but with not
the desired precission.
The file: (takefloat.cpp)
#include <iostream>
#include <fstream>
#include <iomanip>
#include <cstring>
#include <cstdlib>
#include <ctype.h>
using namespace std;
double takeNumber(char*, char*);
int main(){
fstream file;
char name[255];
char buffer[255], numeric[50];
double number;
long int size;
cout << "File for reading: ";
cin >> name;
file.open(name, ios::in);
if (!file){
cerr << "NOT OPENED" << endl;
exit(1);
}
while (!file.eof()){
file.getline(buffer, 254);
number = takeNumber(buffer, numeric);
cout << setprecision(12);
cout << buffer << endl;
cout << "Numeric: " << numeric << "\t" << "Number: " << number << endl;
}
file.close();
system("PAUSE");
return 0;
}
double takeNumber(char* buf, char* numer){
double res;
char* dum;
int i = 0, j;
while (!isdigit(buf[i]) && buf[i] != '-'){
i++;
}
for (j = 0; isdigit(buf[i + j]) || buf[i+j] == '-' || buf[i+j] == '.'; j++)
numer[j] = buf[i + j];
res = strtod(numer, &dum);
return res;
}
The test.txt:
Hello this is the number: -254.1258777 Goodbye!
The result I get is number: -254.12588501
|
|
From: <or...@vp...> - 2002-12-06 19:01:12
|
Hello!
Anders Eriksson wrote:
> You can't introduce new variables in a switch! Move the DWORD style;
> outside and above the switch statement.
Well, that is not exactly true, because you can intorduce variables
wherever you want. You only need to put the declaration with the
corresponding code into a block. So this is also valid:
switch(msg) {
case WM_CREATE:
{ /* --- start of block --- */
DWORD style;
style = (WS_CHILD | WS_VISIBLE); //and others
// ... other code
} /* --- end of block --- */
case WM_DROPFILES:
// ... other code
}
This way you can use local variables, but be aware that the variable you
declared this way is only valid until the end of the block, which it is
in (this case, until the end of the case).
Also this way is better, than putting things before the switch, because
it will be very annoying to scroll up to the beginning of the switch,
when it is VERY long. (Trust me, it WILL be very long)
Of course you are still restricted to place your declarations at the
beginning of the blocks.
If you want to declare anywhere, anytime without blocks, and
restrictions, use C++ :)
--
Best regards
OROSZI Balázs
|
|
From: Daniel G. <sp...@ho...> - 2002-12-06 18:01:06
|
whoops! didn't mean to say put the implementation in the header!
>From: Brenden Towey <br...@rc...>
>To: Daniel Glenfield <sp...@ho...>
>CC: MDo...@OL..., dev...@li...
>Subject: Re: [Dev-C++] FunctionCalling()
>Date: Fri, 06 Dec 2002 09:47:58 -0800
>
>Holy poop, batman! This is the worst idea ever!
>
>Daniel Glenfield wrote:
>
>>You have to use forward declaration.
>
>
>Correct.
>
>>Or type them all out in to a header file, then #include it.
>
>
>No! Never! That is NOT a forward declaration!
>
>Only put the prototype in the header file:
>//Functions.h
>void functionTwo( void );
>
>Then include just the headers in the main program:
>//main.cpp
>#include <iostream>
>#include "Functions.h"
>
>void functionOne( void )
>{
> // ...
>}
>
>void functionTwo( void )
>{
> // ...
>}
>
>// end main.cpp
>
>When you have functions like this, in one source file, it's common just to
>put the prototype in the beginning of that source file and not use a header
>file. However, you often need to call functions elsewhere, so it's not bad
>to get in the habit of putting the prototypes in a header file.
>
>My 2 pence!
>Peace, B.
>
>>
>>
>>// in the header file (Functions.h)
>>
>>int FunctionTwo( int Input )
>>{
>> Input = 365;
>> return Input;
>>}
>>
>>
>>// in the main (.cpp) file
>>#include <iostream.h>
>>#include "Functions.h"
>>
>>
>>int main()
>>{
>> int Input = 0;
>> FunctionTwo( Input );
>> cout << "End";
>> return 0;
>>}
>>
>>
>>P.S. I know that's not the greatest example of coding, but I'm keeping it
>>simple as I got confused by examples when I started.
>>
>>If you need help, post again!
>>
>>
>>
>>>From: Dondolo Mpho <MDo...@OL...>
>>>To: 'dev-cpp-users-list' <dev...@li...>
>>>Subject: [Dev-C++] FunctionCalling()
>>>Date: Fri, 6 Dec 2002 13:05:20 +0200
>>>
>>>Hi all,
>>>
>>>I am in the process of learning C++. I have been practising, writing my
>>>own
>>>functions and using main() only to call those function. I also use those
>>>functions to call up other function....
>>>
>>>//e.g.: function (1)
>>>
>>>void FuctionOne(void)
>>>{
>>>int Answer
>>>cout<<"Are you ready...<press 1 for yes and 2 for no> ";
>>>cin>>Answer;
>>> if(Answer==1)
>>> {
>>>cout<<"\nI am glad that you are";
>>>}
>>>
>>>else
>>> {
>>> FuctionTwo();
>>> }
>>>
>>>}
>>>
>>>//Here I have my
>>>//FunctionTwo
>>>
>>> Now I find that the compiler flags
>>>an
>>>error msg that FunctionTwo has not been declared. it only works when I
>>>take
>>>FunctionTwo() and put it on top of
>>> FunctionOne()....i am I doing
>>>something
>>>wrong? The thing is I might decide halfway through my functions That i
>>>want
>>>function x to call function
>>> y. Now If i have to readjust my
>>>functions half way through, i will loose track of what I am
>>>doing.....Please
>>>help anybody
>>>
>>>
>>>Mpho Dondolo
>>>Support Analyst
>>>CSC Computer Sciences (South Africa) (Pty) Ltd
>>>Tel: +27 21 503030164
>>>cell: +27 84 3371468
>>>Fax: +27 21 5095619
>>>Email:MDo...@ol...
>>>Email: MDo...@cs...
>>>
>>>
>>
>>
>>_________________________________________________________________
>>The new MSN 8: smart spam protection and 2 months FREE*
>>http://join.msn.com/?page=features/junkmail
>>
>>
>>
>>-------------------------------------------------------
>>This sf.net email is sponsored by:ThinkGeek
>>Welcome to geek heaven.
>>http://thinkgeek.com/sf
>>_______________________________________________
>>Dev-cpp-users mailing list
>>Dev...@li...
>>TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
>>https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>>
>>
_________________________________________________________________
Tired of spam? Get advanced junk mail protection with MSN 8.
http://join.msn.com/?page=features/junkmail
|
|
From: Brenden T. <br...@rc...> - 2002-12-06 17:46:30
|
Holy poop, batman! This is the worst idea ever!
Daniel Glenfield wrote:
> You have to use forward declaration.
Correct.
> Or type them all out in to a header file, then #include it.
No! Never! That is NOT a forward declaration!
Only put the prototype in the header file:
//Functions.h
void functionTwo( void );
Then include just the headers in the main program:
//main.cpp
#include <iostream>
#include "Functions.h"
void functionOne( void )
{
// ...
}
void functionTwo( void )
{
// ...
}
// end main.cpp
When you have functions like this, in one source file, it's common just
to put the prototype in the beginning of that source file and not use a
header file. However, you often need to call functions elsewhere, so
it's not bad to get in the habit of putting the prototypes in a header file.
My 2 pence!
Peace, B.
>
>
> // in the header file (Functions.h)
>
> int FunctionTwo( int Input )
> {
> Input = 365;
> return Input;
> }
>
>
> // in the main (.cpp) file
> #include <iostream.h>
> #include "Functions.h"
>
>
> int main()
> {
> int Input = 0;
> FunctionTwo( Input );
> cout << "End";
> return 0;
> }
>
>
> P.S. I know that's not the greatest example of coding, but I'm keeping
> it simple as I got confused by examples when I started.
>
> If you need help, post again!
>
>
>
>> From: Dondolo Mpho <MDo...@OL...>
>> To: 'dev-cpp-users-list' <dev...@li...>
>> Subject: [Dev-C++] FunctionCalling()
>> Date: Fri, 6 Dec 2002 13:05:20 +0200
>>
>> Hi all,
>>
>> I am in the process of learning C++. I have been practising, writing
>> my own
>> functions and using main() only to call those function. I also use those
>> functions to call up other function....
>>
>> //e.g.: function (1)
>>
>> void FuctionOne(void)
>> {
>> int Answer
>> cout<<"Are you ready...<press 1 for yes and 2 for no> ";
>> cin>>Answer;
>> if(Answer==1)
>> {
>> cout<<"\nI am glad that you are";
>> }
>>
>> else
>> {
>> FuctionTwo();
>> }
>>
>> }
>>
>> //Here I have my
>> //FunctionTwo
>>
>> Now I find that the compiler
>> flags an
>> error msg that FunctionTwo has not been declared. it only works when
>> I take
>> FunctionTwo() and put it on top of
>> FunctionOne()....i am I doing
>> something
>> wrong? The thing is I might decide halfway through my functions That
>> i want
>> function x to call function
>> y. Now If i have to readjust my
>> functions half way through, i will loose track of what I am
>> doing.....Please
>> help anybody
>>
>>
>> Mpho Dondolo
>> Support Analyst
>> CSC Computer Sciences (South Africa) (Pty) Ltd
>> Tel: +27 21 503030164
>> cell: +27 84 3371468
>> Fax: +27 21 5095619
>> Email:MDo...@ol...
>> Email: MDo...@cs...
>>
>>
>
>
> _________________________________________________________________
> The new MSN 8: smart spam protection and 2 months FREE*
> http://join.msn.com/?page=features/junkmail
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
>
|
|
From: <h.r...@gm...> - 2002-12-06 16:56:11
|
Hello, after i added C:\Dev-Cpp\include\c++\mingw32 to the compiler path settings, all works well. But why differs the dev-cpp/mingw directory from original mingw directory structure ? It would be simpler to upgrade mingw if there were identical. greetings Horst -- Horst ICQ ID #74808448 www.hroess.net +++ GMX - Mail, Messaging & more http://www.gmx.net +++ NEU: Mit GMX ins Internet. Rund um die Uhr für 1 ct/ Min. surfen! |
|
From: Marcos P. <pa...@ac...> - 2002-12-06 16:38:23
|
Hello all, I've recently got to compile under Dev-C++ an old C++ project I've developed in Unix using Emacs/GCC. Now I got it to compile and run, but I noticed the Dev-C++ class browser makes some confusions: it presents some of the class methods (including some constructors) as global functions and does not recognize namespaces (I think it should create a tree branch for each namespace). Is it normal or am I doing something wrong? Thank you for any help you can provide. Marcos Passini |
|
From: Anders E. <am...@sw...> - 2002-12-06 16:23:38
|
Hello Dreamjunky,
Friday, December 6, 2002, 3:26:03 AM, you wrote:
D> ========================================
D> LRESULT CALLBACK WndProc(HWND handle, UINT msg, WPARAM wp, LPARAM lp) {
D> switch(msg) {
D> case WM_CREATE: // create
D> DWORD style;
D> style = (WS_CHILD | WS_VISIBLE | WS_HSCROLL | WS_VSCROLL | WS_BORDER |
D> ES_LEFT | ES_AUTOHSCROLL | ES_AUTOVSCROLL);
D> CreateWindow(TEXT("EDIT"), NULL, style , 0, 0, CW_USEDEFAULT,
D> CW_USEDEFAULT, handle, (HMENU) FIELD_URL, NULL, NULL);
D> case WM_DESTROY: // close
D> PostQuitMessage(0);
D> return 0;
D> default: // default
D> return DefWindowProc(handle,msg,wp,lp);
D> break;
D> }
D> }
D> =======================================
You can't introduce new variables in a switch! Move the DWORD style;
outside and above the switch statement. E.g.
LRESULT CALLBACK WndProc(HWND handle, UINT msg, WPARAM wp, LPARAM lp)
{
DWORD style;
switch(msg)
{
case WM_CREATE:
style = (WS_CHILD | WS_VISIBLE | WS_HSCROLL | WS_VSCROLL | WS_BORDER | ES_LEFT | ES_AUTOHSCROLL | ES_AUTOVSCROLL);
CreateWindow(TEXT("EDIT"), NULL, style , 0, 0, CW_USEDEFAULT,CW_USEDEFAULT, handle, (HMENU) FIELD_URL, NULL, NULL);
case WM_DESTROY: // close
PostQuitMessage(0);
return 0;
default: // default
return DefWindowProc(handle,msg,wp,lp);
break;
}
}
--
Best regards,
Anders mailto:am...@sw...
|
|
From: Carl F. <de...@st...> - 2002-12-06 16:15:25
|
Hi, I'm trying to set up Dev-C++ to use the borland cbuilder 5.5 compiler. I'm running win98 (rel. 2) Dev-C++ 4.9.6.0 I have set the compiler directories to point to the relevent bcc55 directories, but when it comes to setting the program filenames, I'm not sure which bcc55 ones corresond to the gcc names. The filenames needing set are, gcc, g++, make, gbd, windres, dllwrap, gprof The contents of my \Bcc55\Bin directory are, bcc32.exe, brc32.exe, brcc32.exe, builtins.mak, cc3250.dll, cc3250mt.dll, coff2omf.exe, cpp32.exe, fconvert.exe, grep.exe, ilink32.exe, impdef.exe, implib.exe, lnkdfm50.dll, make.exe, rlink32.dll, rw32core.dll, tdump.exe, tlib.exe, touch.exe, trigraph.exe I think that, gcc should be set to bcc32.exe g++ should be set to cpp32.exe make should be set to make.exe windres should be set to ws32.exe ??? but can't figure out any others. I've been searching google for explanations of each file, to try figure it out myself, but haven't come across anything. Any help with this would be _most_ appreciated! (if anyone has done this already, a copy'n'paste of your DVCPP.ini file would be great!) I posted this question to the dev-cpp-users forum at sourceforge several days ago, but received no reply. My apologies to anyone that has had to read this twice. Carl Franks -- Barry White saved my life. And if Barry White saved your life or got you back with your ex-wife, sing Barry White... Barry White... it's alright... |
|
From: Zodiaq <zo...@ac...> - 2002-12-06 16:07:28
|
Hello Christian and all Dev-C++ users,
Friday, December 6, 2002, 1:49:30 PM, Christian wrote as follows:
CR> I have a problem whuen include commctrl.h header ina a project
CR> i.e.
CR> #include <commctrl.h>
CR> When compile the project i obtain a lot of errors.
CR> Can you help me
First: always write EXACTLY what errors you receieve...
Second: there are two very common problems with commctrl.h:
-did you added -lcomctl32 into linker option??
-some features of common controls require proper version, so before
including ANY files add:
#define _WIN32_IE 0x0501 //or 0x600, but 0x501 is IMO enough
If these doesn't solve your problems let us know...
CR> Christian
--
regards, Zodiaq
|
|
From: Rafael C. <rc...@un...> - 2002-12-06 13:40:16
|
You should use prototypes to define the functions you need
in your main function.=20
Define your prototypes before the main function or
in another file (.h). The code for your functions=20
can be after your "main".
In your case, the prototypes would be:
void FuctionOne(void);
void FuctionTwo(void);
Basically, they are the headers of functions with
a ";" at the end.
So you have, for instance:
1) prototypes
void f1 (void);
void f2 (int);
2) main function
void main() {
...
f1();
f2("an integer");
...
}
3) implementation of the functions you define
void f1 (void) {
int myInt;=20
...
f2(myInt);
...
}
void f2 (int anInt) {
...
}
Read more about prototypes and functions in
http://www.cplusplus.com/doc/tutorial/tut2-2.html
Regards,
Rafael=20
C=F3pia Dondolo Mpho <MDo...@OL...>:
> Hi all,
>=20
> I am in the process of learning C++. I have been practising, writing my
> own
> functions and using main() only to call those function. I also use
> those
> functions to call up other function....
>=20
> //e.g.: function (1)
>=20
> void FuctionOne(void)
> {
> int Answer=20
> cout<<"Are you ready...<press 1 for yes and 2 for no> ";
> cin>>Answer;
> if(Answer=3D=3D1)
> {
> cout<<"\nI am glad that you are";
> }
>=20
> else
> {
> FuctionTwo();
> }
>=20
> }
>=20
> //Here I have my=20
> //FunctionTwo
>=20
> Now I find that the compiler flags
> an
> error msg that FunctionTwo has not been declared. it only works when I
> take
> FunctionTwo() and put it on top of =20
> FunctionOne()....i am I doing
> something
> wrong? The thing is I might decide halfway through my functions That i
> want
> function x to call function=20
> y. Now If i have to readjust my
> functions half way through, i will loose track of what I am
> doing.....Please
> help anybody =20
>=20
> =20
> Mpho Dondolo
> Support Analyst
> CSC Computer Sciences (South Africa) (Pty) Ltd
> Tel: +27 21 503030164
> cell: +27 84 3371468
> Fax: +27 21 5095619
> Email:MDo...@ol...
> Email: MDo...@cs...
> =20
>=20
>=20
|
|
From: Daniel G. <sp...@ho...> - 2002-12-06 12:56:07
|
what are these errors??? >From: "Christian Rossi" <cr...@we...> >To: <dev...@li...> >Subject: [Dev-C++] commctrl.h >Date: Fri, 6 Dec 2002 09:49:30 -0300 > >I have a problem whuen include commctrl.h header ina a project >i.e. >#include <commctrl.h> > >When compile the project i obtain a lot of errors. >Can you help me > >Christian _________________________________________________________________ MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus |
|
From: Christian R. <cr...@we...> - 2002-12-06 12:50:22
|
I have a problem whuen include commctrl.h header ina a project=20 i.e.=20 #include <commctrl.h> When compile the project i obtain a lot of errors. Can you help me=20 Christian |
|
From: Daniel G. <sp...@ho...> - 2002-12-06 12:33:01
|
You have to use forward declaration.
At the moment, when the function is called the compiler says
"what's this? functionTwo()? I don't know about that"
Either write out your functions before your main function, like
#include <iostream.h>
int FunctionTwo( int Input )
{
Input = 365;
return Input;
}
int main()
{
int Input = 0;
FunctionTwo( Input );
cout << "End";
return 0;
}
Or type them all out in to a header file, then #include it.
// in the header file (Functions.h)
int FunctionTwo( int Input )
{
Input = 365;
return Input;
}
// in the main (.cpp) file
#include <iostream.h>
#include "Functions.h"
int main()
{
int Input = 0;
FunctionTwo( Input );
cout << "End";
return 0;
}
P.S. I know that's not the greatest example of coding, but I'm keeping it
simple as I got confused by examples when I started.
If you need help, post again!
>From: Dondolo Mpho <MDo...@OL...>
>To: 'dev-cpp-users-list' <dev...@li...>
>Subject: [Dev-C++] FunctionCalling()
>Date: Fri, 6 Dec 2002 13:05:20 +0200
>
>Hi all,
>
>I am in the process of learning C++. I have been practising, writing my own
>functions and using main() only to call those function. I also use those
>functions to call up other function....
>
>//e.g.: function (1)
>
>void FuctionOne(void)
>{
>int Answer
>cout<<"Are you ready...<press 1 for yes and 2 for no> ";
>cin>>Answer;
> if(Answer==1)
> {
>cout<<"\nI am glad that you are";
>}
>
>else
> {
> FuctionTwo();
> }
>
>}
>
>//Here I have my
>//FunctionTwo
>
> Now I find that the compiler flags an
>error msg that FunctionTwo has not been declared. it only works when I take
>FunctionTwo() and put it on top of
> FunctionOne()....i am I doing
>something
>wrong? The thing is I might decide halfway through my functions That i want
>function x to call function
> y. Now If i have to readjust my
>functions half way through, i will loose track of what I am
>doing.....Please
>help anybody
>
>
>Mpho Dondolo
>Support Analyst
>CSC Computer Sciences (South Africa) (Pty) Ltd
>Tel: +27 21 503030164
>cell: +27 84 3371468
>Fax: +27 21 5095619
>Email:MDo...@ol...
>Email: MDo...@cs...
>
>
_________________________________________________________________
The new MSN 8: smart spam protection and 2 months FREE*
http://join.msn.com/?page=features/junkmail
|
|
From: <jar...@ig...> - 2002-12-06 12:32:02
|
On 6 Dec, Dondolo Mpho wrote:
> Hi all,
>
> I am in the process of learning C++. I have been practising, writing my own
> functions and using main() only to call those function. I also use those
> functions to call up other function....
>
> //e.g.: function (1)
HERE you need a so-called forward declaration
just say
void FunctionTwo(); // <=== note the semi-colon here
// at a later point or within a different file
// you define the 'real' function with the SAME
// function header
>
> void FuctionOne(void)
> {
> int Answer
> cout<<"Are you ready...<press 1 for yes and 2 for no> ";
> cin>>Answer;
> if(Answer==1)
> {
> cout<<"\nI am glad that you are";
> }
>
> else
> {
> FuctionTwo();
> }
>
> }
>
> //Here I have my
> //FunctionTwo
>
> Now I find that the compiler flags an
> error msg that FunctionTwo has not been declared. it only works when I take
> FunctionTwo() and put it on top of
> FunctionOne()....i am I doing something
> wrong? The thing is I might decide halfway through my functions That i want
> function x to call function
> y. Now If i have to readjust my
> functions half way through, i will loose track of what I am doing.....Please
> help anybody
>
--
Helmut Jarausch
Lehrstuhl fuer Numerische Mathematik
Aachen University
D 52056 Aachen, Germany
|
|
From: <qa...@ho...> - 2002-12-06 11:43:44
|
If you type in the path manually or press the <...> button for= path-browsing, the <Add> button will highlight. /J *********** REPLY SEPARATOR *********** On 2002-12-06 at 09:16 jar...@ig... wrote: >On 4 Dec, Colin Laplace wrote: >> Hi ! >> >> Dev-C++ 4.9.7.0 is finally available ! >> This release should be fairly stable and provides many improvements >since >> version 4.9.6.0. > >Many thanks, >but I must have missed something. > >I've install the gcc32 version and the most simple >Hello World programme doesn't work anymore >(I have no problems with 4.9.6.0 + Ming2 installed > above it) > >#include <iostream> > >gives the error message >bits/c++config.h no such file or directory > >obviously an additional include PATH is missing: >C:\Dev-Cpp\include\c++\mingw32 > >unfortunately I cannot add this for the default compiler >since the <Add> button is dimmed. >Where can I add this additional include path? > >Many thanks for a hint, > >Helmut Jarausch > >Lehrstuhl fuer Numerische Mathematik >Aachen University >D 52056 Aachen, Germany > > > > >------------------------------------------------------- >This sf.net email is sponsored by:ThinkGeek >Welcome to geek heaven. >http://thinkgeek.com/sf >_______________________________________________ >Dev-cpp-users mailing list >Dev...@li... >TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm >https://lists.sourceforge.net/lists/listinfo/dev-cpp-users |
|
From: Carlos d. M. <cg...@wo...> - 2002-12-06 11:30:59
|
Tools->Compiler Options->directories. Select the include directories for C or C++, or lib or whatever, then ent= er the directory in the lower edit field and press add. What you say about default compiler makes me think you are talking about = the first tab, that doesn't do anything about the directories, it is for chan= ge the compiler dev will call. jar...@ig... escribi=F3: > On 4 Dec, Colin Laplace wrote: > > Hi ! > > > > Dev-C++ 4.9.7.0 is finally available ! > > This release should be fairly stable and provides many improvements s= ince > > version 4.9.6.0. > > Many thanks, > but I must have missed something. > > I've install the gcc32 version and the most simple > Hello World programme doesn't work anymore > (I have no problems with 4.9.6.0 + Ming2 installed > above it) > > #include <iostream> > > gives the error message > bits/c++config.h no such file or directory > > obviously an additional include PATH is missing: > C:\Dev-Cpp\include\c++\mingw32 > > unfortunately I cannot add this for the default compiler > since the <Add> button is dimmed. > Where can I add this additional include path? > > Many thanks for a hint, > > Helmut Jarausch > > Lehrstuhl fuer Numerische Mathematik > Aachen University > D 52056 Aachen, Germany > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > Dev-cpp-users mailing list > Dev...@li... > TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users |
|
From: Dondolo M. <MDo...@OL...> - 2002-12-06 11:10:30
|
Hi all,
I am in the process of learning C++. I have been practising, writing my own
functions and using main() only to call those function. I also use those
functions to call up other function....
//e.g.: function (1)
void FuctionOne(void)
{
int Answer
cout<<"Are you ready...<press 1 for yes and 2 for no> ";
cin>>Answer;
if(Answer==1)
{
cout<<"\nI am glad that you are";
}
else
{
FuctionTwo();
}
}
//Here I have my
//FunctionTwo
Now I find that the compiler flags an
error msg that FunctionTwo has not been declared. it only works when I take
FunctionTwo() and put it on top of
FunctionOne()....i am I doing something
wrong? The thing is I might decide halfway through my functions That i want
function x to call function
y. Now If i have to readjust my
functions half way through, i will loose track of what I am doing.....Please
help anybody
Mpho Dondolo
Support Analyst
CSC Computer Sciences (South Africa) (Pty) Ltd
Tel: +27 21 503030164
cell: +27 84 3371468
Fax: +27 21 5095619
Email:MDo...@ol...
Email: MDo...@cs...
|
|
From: <jar...@ig...> - 2002-12-06 10:22:29
|
On 4 Dec, Colin Laplace wrote: > Hi ! > > Dev-C++ 4.9.7.0 is finally available ! > This release should be fairly stable and provides many improvements since > version 4.9.6.0. Many thanks, but I must have missed something. I've install the gcc32 version and the most simple Hello World programme doesn't work anymore (I have no problems with 4.9.6.0 + Ming2 installed above it) #include <iostream> gives the error message bits/c++config.h no such file or directory obviously an additional include PATH is missing: C:\Dev-Cpp\include\c++\mingw32 unfortunately I cannot add this for the default compiler since the <Add> button is dimmed. Where can I add this additional include path? Many thanks for a hint, Helmut Jarausch Lehrstuhl fuer Numerische Mathematik Aachen University D 52056 Aachen, Germany |
|
From: Dreamjunky <li...@dr...> - 2002-12-06 02:26:24
|
> It looks like compiler doesn't see what DWORD is... have you included
> windows.h??? DWORD is defind in one of other headers included from
> <windows.h>, exactly in <windef.h> as:
> typedef unsigned long DWORD;
>
Hello again,
Yeah I have windows included. And if anybody needs it, here's the entire
function that the code's in:
========================================
LRESULT CALLBACK WndProc(HWND handle, UINT msg, WPARAM wp, LPARAM lp) {
switch(msg) {
case WM_CREATE: // create
DWORD style;
style = (WS_CHILD | WS_VISIBLE | WS_HSCROLL | WS_VSCROLL | WS_BORDER |
ES_LEFT | ES_AUTOHSCROLL | ES_AUTOVSCROLL);
CreateWindow(TEXT("EDIT"), NULL, style , 0, 0, CW_USEDEFAULT,
CW_USEDEFAULT, handle, (HMENU) FIELD_URL, NULL, NULL);
case WM_DESTROY: // close
PostQuitMessage(0);
return 0;
default: // default
return DefWindowProc(handle,msg,wp,lp);
break;
}
}
=======================================
Doesn't look to pretty in email but any ideas I'd greatly appreciate. I'm
still stumped (for two days now)
Thanks
Tvienti
|