dev-cpp-users Mailing List for Dev-C++ (Page 332)
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: wavemechanic <wd...@co...> - 2003-08-11 14:43:01
|
Add the stuff shown
----- Original Message -----=20
From: "Dawood Vora" <da...@ku...>
To: "Dev C++" <dev...@li...>
Sent: Monday, August 11, 2003 5:11 AM
Subject: [Dev-C++] what is wrong with the code
> can anybody let me know, why the code below is not running.
>=20
>=20
> #include <iostream.h>
> #include <stdlib.h>
> #include <string>
>=20
using namespace std;
>=20
> int main()
> {
> char ch =3D 'z';
> string p =3D "ch";
>=20
> p.push_back(ch);
>=20
> system("PAUSE");
> return 0;
> }
>=20
>=20
>=20
> -------------------------------------------------------
> This SF.Net email sponsored by: Free pre-built ASP.NET sites including
> Data Reports, E-commerce, Portals, and Forums are available now.
> Download today and enter to win an XBOX or Visual Studio .NET.
> =
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/=
01
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users |
|
From: Kevin W. <ke...@me...> - 2003-08-11 13:05:16
|
Hi everyone, At 01:53 11/08/03, Chris Sroka wrote: >I have created an OK pushbutton in a dialog box via a resource script (see >code below): > >**** > > DEFPUSHBUTTON "Start", ID_START_CALC, 255, 7, 50, 14 > DEFPUSHBUTTON "OK", ID_OK, 255, 27, 50, 14 > DEFPUSHBUTTON "Cancel", ID_CANCEL, 255, 47, 50, 14 >**** There should only be one default button in a dialog box. Use PUSHBUTTON for the rest. >I am trying to grey it out and disable it, from within a callback >function, while I carry out some calculations, and then enable it again >when the calcs are complete. Buttons are windows, so you can send a message to the button to disable it, via the EnableWindow function: EnableWindow(HWND hWnd, BOOL bEnable) where hWnd is the window handle, and bEnable is set to FALSE to disable the window. >Does anyone know how to do this? I have tried SendDlgItemMessage with the >dialog's handle, the pushbutton's ID and various LPARAMs and WPARAMs but >with no success. I have also trawled www.msdn.microsoft.com but found no >suggestions. Do you have the Win32 SDK? Regards, Kev. |
|
From: Per W. <pw...@ia...> - 2003-08-11 10:31:13
|
On one hand, tne lines of code you sent are trivial to look at.
However, it is recommended that you always specify:
- What happens - compiler errors, linker errors, run-time behaviour etc.
- What did you expect to happen.
/Per W
On Mon, 11 Aug 2003, Dawood Vora wrote:
> can anybody let me know, why the code below is not running.
>
>
> #include <iostream.h>
> #include <stdlib.h>
> #include <string>
>
>
> int main()
> {
> char ch = 'z';
> string p = ch;
>
> p.push_back(ch);
>
> system("PAUSE");
> return 0;
> }
>
>
>
> -------------------------------------------------------
> This SF.Net email sponsored by: Free pre-built ASP.NET sites including
> Data Reports, E-commerce, Portals, and Forums are available now.
> Download today and enter to win an XBOX or Visual Studio .NET.
> http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
|
|
From: Dawood V. <da...@ku...> - 2003-08-11 09:30:31
|
can anybody let me know, why the code below is not running.
#include <iostream.h>
#include <stdlib.h>
#include <string>
int main()
{
char ch = 'z';
string p = ch;
p.push_back(ch);
system("PAUSE");
return 0;
}
|
|
From: Tom H <to...@sc...> - 2003-08-11 03:31:03
|
Hello list,
A quick question;
I downloaded a copy of dev-C++ and opened up the hello world example. It =
looked OK
to me so I did a compile and run without changing anything. But there =
were some compiler
errors which prevented it from finishing.
Any idea what I have done to screw up these include files?
(I've posted the compiler output below;)
Cheers
T.
******************************************
Compiler: Default compiler
Building Makefile: "C:\Dev-Cpp\Makefile.win"
Executing make...
make.exe -f "C:\Dev-Cpp\Makefile.win" all
g++.exe -c Untitled1.cpp -o Untitled1.o -I"C:/Dev-Cpp/include/c++" =
-I"C:/Dev-Cpp/include/c++/mingw32" -I"C:/Dev-Cpp/include/c++/backward" =
-I"C:/Dev-Cpp/include" In file included from =
C:/Dev-Cpp/include/windows.h:98,
from =
C:/Dev-Cpp/include/c++/mingw32/bits/gthr-default.h:462,
from C:/Dev-Cpp/include/c++/mingw32/bits/gthr.h:98,
from C:/Dev-Cpp/include/c++/mingw32/bits/c++io.h:37,
from C:/Dev-Cpp/include/c++/bits/fpos.h:44,
from C:/Dev-Cpp/include/c++/iosfwd:46,
from C:/Dev-Cpp/include/c++/ios:44,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from Untitled1.cpp:1:
C:/Dev-Cpp/include/winsock2.h:95:2: warning: #warning "fd_set and =
associated macros have been defined in sys/types. This may cause =
runtime problems with W32 sockets"=20
In file included from C:/Dev-Cpp/include/c++/bits/locale_facets.h:63,
from C:/Dev-Cpp/include/c++/bits/basic_ios.h:41,
from C:/Dev-Cpp/include/c++/ios:51,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45, =
from Untitled1.cpp:1:
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:44: `_UPPER' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:45: `_LOWER' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:46: `_ALPHA' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:47: `_DIGIT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:48: `_HEX' was not =
declared in=20
this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:49: `_SPACE' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:50: `_BLANK' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:50: `_PUNCT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:50: `_ALPHA' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:50: `_DIGIT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:51: `_PUNCT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:51: `_ALPHA' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:51: `_DIGIT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:52: `_CONTROL' was not=20
declared in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:53: `_PUNCT' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:54: `_ALPHA' was not =
declared=20
in this scope
C:/Dev-Cpp/include/c++/mingw32/bits/ctype_base.h:54: `_DIGIT' was not =
declared=20
in this scope In file included from =
C:/Dev-Cpp/include/c++/bits/locale_facets.tcc:41,
from C:/Dev-Cpp/include/c++/locale:46,
from C:/Dev-Cpp/include/c++/bits/ostream.tcc:37,
from C:/Dev-Cpp/include/c++/ostream:275, =
from C:/Dev-Cpp/include/c++/iostream:45,
from Untitled1.cpp:1:
C:/Dev-Cpp/include/c++/cmath: In function `long double std::acos(long =
double)':
C:/Dev-Cpp/include/c++/cmath:109: `::acosl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::asin(long =
double)':
C:/Dev-Cpp/include/c++/cmath:127: `::asinl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::atan(long =
double)':
C:/Dev-Cpp/include/c++/cmath:145: `::atanl' undeclared (first use here) =
C:/Dev-Cpp/include/c++/cmath: In function `long double std::atan2(long =
double,=20
long double)':
C:/Dev-Cpp/include/c++/cmath:164: `::atan2l' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::ceil(long =
double)':
C:/Dev-Cpp/include/c++/cmath:183: `::ceill' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::cosh(long =
double)':
C:/Dev-Cpp/include/c++/cmath:211: `::coshl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::exp(long =
double)':
C:/Dev-Cpp/include/c++/cmath:229: `::expl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::floor(long=20
double)':
C:/Dev-Cpp/include/c++/cmath:257: `::floorl' undeclared (first use here) =
C:/Dev-Cpp/include/c++/cmath: In function `long double std::fmod(long =
double, long double)':
C:/Dev-Cpp/include/c++/cmath:276: `::fmodl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::frexp(long =
double,=20
int*)':
C:/Dev-Cpp/include/c++/cmath:295: `::frexpl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::ldexp(long =
double,=20
int)':
C:/Dev-Cpp/include/c++/cmath:315: `::ldexpl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::log(long =
double)':
C:/Dev-Cpp/include/c++/cmath:334: `::logl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::log10(long=20
double)':
C:/Dev-Cpp/include/c++/cmath:352: `::log10l' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::modf(long =
double,=20
long double*)':
C:/Dev-Cpp/include/c++/cmath:376: `::modfl' undeclared (first use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::pow(long =
double,=20
long double)':
C:/Dev-Cpp/include/c++/cmath:410: `::powl' undeclared (first use here) =
C:/Dev-Cpp/include/c++/cmath: In function `long double std::sinh(long =
double)':
C:/Dev-Cpp/include/c++/cmath:451: `::sinhl' undeclared (first use here) =
C:/Dev-Cpp/include/c++/cmath: In function `long double std::tan(long =
double)': C:/Dev-Cpp/include/c++/cmath:479: `::tanl' undeclared (first =
use here)
C:/Dev-Cpp/include/c++/cmath: In function `long double std::tanh(long =
double)':
C:/Dev-Cpp/include/c++/cmath:497: `::tanhl' undeclared (first use here) =
make.exe: *** [Untitled1.o] Error 1 Execution terminated
|
|
From: pErCivaL <pma...@nt...> - 2003-08-11 03:23:22
|
Add.. -lws2_32 ..in your project options' linker parameter. -Pers > Message: 1 > Date: Sun, 10 Aug 2003 14:19:48 -0300 (ART) > From: =3D?iso-8859-1?q?Rhuan=3D20Barros?=3D <rhu...@ya...> > To: dev...@li... > Subject: [Dev-C++] problema com winsock > > estou com um problema para compilar um programa feito > todo com winsock. > > na hora de compilar aparece o seguinte erro: > > [Linker error] undefined reference to > `gethostbyname@4' > [Linker error] undefined reference to `socket@12' > [Linker error] undefined reference to `htons@4' [Linker error] undefine= d=20 > reference to `sendto@24' [Linker error] undefined reference to=20 > `inet_ntoa@4' [Linker error] undefined reference to `closesocket@4'=20 > [Linker error] undefined reference to `WSACleanup@0' [Linker error]=20 > undefined reference to `WSAStartup@8' > > eu ja conpilei este programa com o C builder 6 e n=C3=A3o > tive este problema, ele s=C3=B3 acontece com o devc++. > --=20 Data asks, "Sir, how is it that the Q can handle time and space so well a= nd=20 us so badly?" and Picard replies aphoristically, "Perhaps someday we will= =20 discover that space and time are simpler than the human equation." mortality gives life focus and purpose -- |
|
From: Chris S. <CS...@Ai...> - 2003-08-11 00:53:44
|
I have created an OK pushbutton in a dialog box via a resource script =
(see code below):=20
****
DEFPUSHBUTTON "Start", ID_START_CALC, 255, 7, 50, 14
DEFPUSHBUTTON "OK", ID_OK, 255, 27, 50, 14
DEFPUSHBUTTON "Cancel", ID_CANCEL, 255, 47, 50, 14
****
I am trying to grey it out and disable it, from within a callback =
function, while I carry out some calculations, and then enable it again =
when the calcs are complete.=20
Does anyone know how to do this? I have tried SendDlgItemMessage with =
the dialog's handle, the pushbutton's ID and various LPARAMs and WPARAMs =
but with no success. I have also trawled www.msdn.microsoft.com but =
found no suggestions.=20
Regards=20
Chris Sroka=20
|
|
From: Per W. <pw...@ia...> - 2003-08-10 23:09:28
|
Use Sleep(DWORD ms) as delay. It's declared in winbase.h. /Per W On Sun, 10 Aug 2003, Rhuan Barros wrote: > algu=E9m conhece alguma fun=E7=E3o alternativa as delay, > random, randomize do turbo c++, para o dev c++, > agrade=E7o desde j=E1! > > -------english------tranlated with google > > somebody knows some function alternative delay, > random, randomize of the turbo c++, for dev c++, is > thankful since already! > > _______________________________________________________________________ > Conhe=E7a o novo Cad=EA? - Mais r=E1pido, mais f=E1cil e mais preciso. > Toda a web, 42 milh=F5es de p=E1ginas brasileiras e nova busca por imagen= s! > http://www.cade.com.br > > > ------------------------------------------------------- > This SF.Net email sponsored by: Free pre-built ASP.NET sites including > Data Reports, E-commerce, Portals, and Forums are available now. > Download today and enter to win an XBOX or Visual Studio .NET. > http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/= 01 > _______________________________________________ > Dev-cpp-users mailing list > Dev...@li... > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > |
|
From: <or...@vp...> - 2003-08-10 22:35:45
|
Rhuan Barros wrote: > estou com um problema para compilar um programa feito > todo com winsock. > > na hora de compilar aparece o seguinte erro: > > [Linker error] undefined reference to > `gethostbyname@4' > [Linker error] undefined reference to `socket@12' > [Linker error] undefined reference to `htons@4' > [Linker error] undefined reference to `sendto@24' > [Linker error] undefined reference to `inet_ntoa@4' > [Linker error] undefined reference to `closesocket@4' > [Linker error] undefined reference to `WSACleanup@0' > [Linker error] undefined reference to `WSAStartup@8' Add -lwsock32 to your linker (to the libraries). -- Greetings, Balázs |
|
From: <ri...@te...> - 2003-08-10 20:24:38
|
Ricardo Amores Hernández escribió:
I´ve have such a terrible english :( :(
Use this header and you should be able to use random() and randomize().
But I encourage you
to get used to rand() and srand() C standard functions
> #ifndef __MY_RANDOM__
> #define __MY_RANDOM__
>
> #ifndef _TIME_H_
> #include <time.h>
> #endif
>
> #ifndef _STDLIB_H_
> #include <stdlib.h>
> #endif
>
> #define randomize() srand(time(NULL))
Sorry, there was mistake in this line
#define random(x) (rand() % (x))
//was #define random(x) (rand() % (x)) +1 )
> #endif /* __MY_RANDOM__ */
>
>
> I don´t know a delay(), but you could use a conio library for Dev-C++.
> Here you have one (Spanish link)
By the way, when I said "I don´t know", I mean: "There is no delay() or
similar function in C nor C++ standard library" ;)
--
---------------------------------------------------
Ricardo Amores Hernández
ICQ: 19463735
MSN: zheo_ (at) hotmail (dot) es
---------------------------------------------------
|
|
From: <ri...@te...> - 2003-08-10 19:42:45
|
Rhuan Barros escribió:
> -------english------tranlated with google
>
> somebody knows some function alternative delay,
> random, randomize of the turbo c++, for dev c++, is
> thankful since already!
Use this header and you could use random() and randomize(). But you
should get used to the rand() and srand() C standard functions
#ifndef __MY_RANDOM__
#define __MY_RANDOM__
#ifndef _TIME_H_
#include <time.h>
#endif
#ifndef _STDLIB_H_
#include <stdlib.h>
#endif
#define randomize() srand(time(NULL))
#define random(x) (rand() % (x)) +1
#endif /* __MY_RANDOM__ */
I don´t know a delay(), but you could use a conio library for Dev-C++.
Here you have one (Spanish link)
http://c.conclase.net/conio/index.php
Regards
--
---------------------------------------------------
Ricardo Amores Hernández
ICQ: 19463735
MSN: zheo_ (at) hotmail (dot) es
---------------------------------------------------
|
|
From: <rhu...@ya...> - 2003-08-10 19:12:37
|
alguém conhece alguma função alternativa as delay, random, randomize do turbo c++, para o dev c++, agradeço desde já! -------english------tranlated with google somebody knows some function alternative delay, random, randomize of the turbo c++, for dev c++, is thankful since already! _______________________________________________________________________ Conheça o novo Cadê? - Mais rápido, mais fácil e mais preciso. Toda a web, 42 milhões de páginas brasileiras e nova busca por imagens! http://www.cade.com.br |
|
From: <rhu...@ya...> - 2003-08-10 17:19:48
|
estou com um problema para compilar um programa feito todo com winsock. na hora de compilar aparece o seguinte erro: [Linker error] undefined reference to `gethostbyname@4' [Linker error] undefined reference to `socket@12' [Linker error] undefined reference to `htons@4' [Linker error] undefined reference to `sendto@24' [Linker error] undefined reference to `inet_ntoa@4' [Linker error] undefined reference to `closesocket@4' [Linker error] undefined reference to `WSACleanup@0' [Linker error] undefined reference to `WSAStartup@8' eu ja conpilei este programa com o C builder 6 e não tive este problema, ele só acontece com o devc++. _______________________________________________________________________ Conheça o novo Cadê? - Mais rápido, mais fácil e mais preciso. Toda a web, 42 milhões de páginas brasileiras e nova busca por imagens! http://www.cade.com.br |
|
From: P.D. v. Z. <pa...@my...> - 2003-08-09 13:13:38
|
I assume you don't mean a part of the actual program code, but data
entered while running your program. Depending on whether you use C or
C++, you need to either do:
(C code)
FILE* out = fopen("somefilename", "wt"); /* or "wb" for binary files */
fprintf(out, "Blah blah blah"); /* for text files */
fwrite(buf, size_of_buf, number_of_items, out); /* for binary files */
fclose(out);
OR (C++ code):
#include <fstream>
// ....
std::ofstream out("somefile");
out << "Blah blah blah";
Hope this helped,
Paul
P.S.: Specifying a subject next time you ask a question would be nice,
and giving your brain some exercise by searching for things yourself
first would be even better.
-----Original Message-----
From: dev...@li...
[mailto:dev...@li...] On Behalf Of yiwei li
Sent: Saturday, August 09, 2003 1:58 PM
To: dev...@li...
Subject: [Dev-C++] (no subject)
how can i save part of a programme in a file and able to retrieve it the
next time when i run the programme?
Get 10mb of e-mail space with MSN Hotmail Extra Storage at only S$36 per
year including GST
------------------------------------------------------- This SF.Net
email sponsored by: Free pre-built ASP.NET sites including Data Reports,
E-commerce, Portals, and Forums are available now. Download today and
enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01
/01 _______________________________________________ Dev-cpp-users
mailing list Dev...@li... TO UNSUBSCRIBE:
http://www23.brinkster.com/noicys/devcpp/ub.htm
https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
|
|
From: yiwei l. <liy...@ho...> - 2003-08-09 11:58:05
|
<html><div style='background-color:'><DIV> <P><BR>how can i save part of a programme in a file and able to retrieve it the next time when i run the programme? <BR></P></DIV></div><br clear=all><hr>Get 10mb of e-mail space with <a href="http://g.msn.com/8HMVENSG/2737??PS=">MSN Hotmail Extra Storage</a> at only S$36 per year including GST</html> |
|
From: iad929 <ia...@jo...> - 2003-08-09 07:07:17
|
Hi... I have installed this version of DEV-C++ on Win98. I openned Windows = Explorer and clicked on a C++ file to open it in DEV-C++. The file is = openned with an error message saying "Cannot find the file 'blah blah' = (or one of its components)." The error is harmless because the file is openned successfully but it is = annoying. Mohammed |
|
From: <ri...@te...> - 2003-08-08 21:00:50
|
André Macário Barros escribió: > Thank you, Mr. Ricardo, but... > > listen for the report: > A lot of mirror sites reported this problem. > After post the message, I´ve tried the most distant mirror site: > C-View.org (China) > I downloaded it without problems and installed the software! > > Are the other sites with an installer corrupted or virus infected? > Or both? Or neither? Maybe is your computer the one witch has a virus, so when you try to install, it gets corrupted by the virus. Just a chance. Regards |
|
From: <and...@su...> - 2003-08-08 20:16:53
|
Thank you, Mr. Ricardo, but... listen for the report: A lot of mirror sites reported this problem. After post the message, I´ve tried the most distant mirror site: C-View.org (China) I downloaded it without problems and installed the software! Are the other sites with an installer corrupted or virus infected? Or both? Or neither? Regards Andre Barros -----Mensagem original----- De: Ricardo Amores Hernández [mailto:ri...@te...] Enviada em: sexta-feira, 8 de agosto de 2003 16:23 Para: André Macário Barros Cc: Dev-Cpp-Users Assunto: Re: [Dev-C++] Problems Installing Beta 5 André Macário Barros escribió: > This could be the result of corruption from a virus. Check this line ;) It happened to me with a game patch. The patch refused to install because file sizes mismatch. The file had been modified by a virus :( If it isn´t the problem, try checking your hard drive with chkdsk command. Regards -- --------------------------------------------------- Ricardo Amores Hernández ICQ: 19463735 MSN: zheo_ (at) hotmail (dot) es --------------------------------------------------- |
|
From: <ri...@te...> - 2003-08-08 19:23:14
|
André Macário Barros escribió:
> This could be the result of corruption from a virus.
Check this line ;)
It happened to me with a game patch. The patch refused to install
because file sizes mismatch. The file had been modified by a virus :(
If it isn´t the problem, try checking your hard drive with chkdsk command.
Regards
--
---------------------------------------------------
Ricardo Amores Hernández
ICQ: 19463735
MSN: zheo_ (at) hotmail (dot) es
---------------------------------------------------
|
|
From: <and...@su...> - 2003-08-08 18:43:46
|
Dear Users,
When I try to run the devcpp4980.exe (beta 5), the following
message appears:
"Installer corrupted or incomplete.
This could be the result of a failed download or corruption from
a virus.
If desperate, try the /NCRC command line switch (NOT recommended)"
I did not try this switch. First I would like to know what is
happening with you, gurus.
ps1: I´ve tried a lot of different mirror sites and the same problem
still appears.
ps2: WinXp computer
Regards
Andre Barros
|
|
From: FerretallicA <fer...@ho...> - 2003-08-08 07:27:45
|
Hrmph...
It appears I am a moron and can't manage to reply to the list instead of to
individuals. It would explain a few things... anyways the following to the
list just for reference. If anyone else has problems with DirectInput it
might help them...
Cheers,
-FerretallicA
MESSAGE 1:
Oo oi,
No more c_dfDIKeyboard errors... and yes I know what SDL is :)
Thanks to all who have offered their input (no pun intended)!
Cheers,
-FerretallicA
----- Original Message -----
From: Damien
To: dev...@li...
Sent: Thursday, August 07, 2003 11:36 PM
Subject: Re: [Dev-C++] Direct Input Problems
Yeah, I did, but I had to 'borrow' a few lines out of the SDL source. The
only problem you should be having is the linker error involving
c_dfDIKeyboard. Take a look at SDL_dx5video.c, and copy and paste the
definitions in your code. Copy "static DIOBJECTDATAFORMAT KBD_fmt" and
"const DIDATAFORMAT c_dfDIKeyboard". Its a whole lot of code, so I won't
paste it in here. Just place it at the end of your source code. You do know
what SDL is ...right?
MESSAGE 2:
Oo oi,
I tried it out and it still gives this problem-
[Linker error] undefined reference to `c_dfDIMouse'
Thanks for the help still!
Cheers,
-FerretallicA
----- Original Message -----
From: "w.y." <yok...@be...>
Cc: "Dev-C++ Users Mailing List" <dev...@li...>
Sent: Thursday, August 07, 2003 7:47 PM
Subject: Re: [Dev-C++] Direct Input Problems
I copied and pasted from the examples from my book and got something
working. This uses Direct Input to read the mouse. It would take some
more tweaking to get something more useful, but this is something
at least. Assuming you have some basic windows app with menu choices,
pick a menu choice to use and call the 3 functions like this:
initDImouse(MainInstance, hwnd);
readDIMouse(hwnd);
shutDownDImouse();
"MainInstance" is a global I'm using obtained from the HINSTANCE
you get from WinMain. "hwnd" you probably know..
Merge the code below with your app, or put in a separate file (you'll
need to make a header file). The only library I included was
libdinput8.a (and libwinmm.a for something else) and I'm using
DevC++ 4.9.8.0
This all compiles with no problem for me.
////////////////////////////////////////////////////////////////
#define INITGUID
#include<windows.h>
#include<windowsx.h>
#include<dinput.h>
#include<cstdio>
#include"DImouse.h"
LPDIRECTINPUT8 lpdi = NULL; // dinput object
LPDIRECTINPUTDEVICE8 lpdimouse = NULL; // dinput mouse
const int winWidth = 640;
const int winHeight = 480;
int initDImouse(HINSTANCE, HWND);
int shutDownDImouse();
int readDIMouse(HWND);
int initDImouse(HINSTANCE hinstance,HWND hwnd)
{
DirectInput8Create(hinstance,DIRECTINPUT_VERSION,IID_IDirectInput8,
(void **)&lpdi,NULL);
// create a mouse device /////////////////////////////////////
lpdi->CreateDevice(GUID_SysMouse, &lpdimouse, NULL);
// set cooperation level
lpdimouse->SetCooperativeLevel(hwnd, DISCL_NONEXCLUSIVE |
DISCL_BACKGROUND);
// set data format
lpdimouse->SetDataFormat(&c_dfDIMouse);
// acquire the mouse
lpdimouse->Acquire();
return 1;
}
int shutDownDImouse()
{
// first unacquire the mouse
lpdimouse->Unacquire();
// now release the mouse
lpdimouse->Release();
// release directinput
lpdi->Release();
return 1;
}
int readDIMouse(HWND hwnd)
{
DIMOUSESTATE mouse_state;
int mouse_x = winWidth >> 1,
mouse_y = winHeight >> 1, prevX=mouse_x, prevY=mouse_y;
HDC hdc = GetDC(hwnd);
do
{ // get the input from the mouse
lpdimouse->GetDeviceState(sizeof(DIMOUSESTATE), (LPVOID)&mouse_state);
// move the mouse cursor
mouse_x += (mouse_state.lX); // relative movement
mouse_y += (mouse_state.lY); // returned....
// test bounds
// first x boundaries
if (mouse_x >= winWidth) mouse_x = winWidth-1;
else if (mouse_x < 0) mouse_x = 0;
// now the y boundaries
if (mouse_y >= winHeight) mouse_y= winHeight-1;
else if (mouse_y < 0) mouse_y = 0;
// Update output if changed
if ( (prevX != mouse_x) || (prevY != mouse_y) )
{
prevX = mouse_x; prevY = mouse_y;
char strbuf[250];
sprintf(strbuf,"Right click to exit. Direct Mouse: %3i, %3i
",mouse_x, mouse_y);
TextOut(hdc,10,20,strbuf,strlen(strbuf));
}
} while ( !mouse_state.rgbButtons[0] );
ReleaseDC(hwnd,hdc);
return 1;
}
|
|
From: Damien <g_...@ho...> - 2003-08-07 13:36:17
|
<html><div style='background-color:'><DIV> <P>Yeah, I did, but I had to 'borrow' a few lines out of the SDL source. The only problem you should be having is the linker error involving c_dfDIKeyboard. Take a look at SDL_dx5video.c, and copy and paste the definitions in your code. Copy "static DIOBJECTDATAFORMAT KBD_fmt" and "const DIDATAFORMAT c_dfDIKeyboard". Its a whole lot of code, so I won't paste it in here. Just place it at the end of your source code. You do know what SDL is ...right?<BR><BR></P></DIV> <DIV></DIV>----Original Message Follows---- <DIV></DIV>From: "FerretallicA" <FER...@HO...> <DIV></DIV>To: "Dev-C++ Users Mailing List" <DEV...@LI...> <DIV></DIV>Subject: [Dev-C++] Direct Input Problems <DIV></DIV>Date: Thu, 7 Aug 2003 17:37:04 +1000 <DIV></DIV> <DIV></DIV>Oo oi, <DIV></DIV> <DIV></DIV>Still no luck. This is a f**king nightmare. Mayhaps a different approach... <DIV></DIV>instead of asking who has a solution to getting it working, how about I ask <DIV></DIV>this- put your hands up if you have DirectInput working in DevC++ 4.x... am <DIV></DIV>I the only one having problems with it? <DIV></DIV> <DIV></DIV>Cheers, <DIV></DIV>-FerretallicA <DIV></DIV> <DIV></DIV> <DIV></DIV>------------------------------------------------------- <DIV></DIV>This SF.Net email sponsored by: Free pre-built ASP.NET sites including <DIV></DIV>Data Reports, E-commerce, Portals, and Forums are available now. <DIV></DIV>Download today and enter to win an XBOX or Visual Studio .NET. <DIV></DIV>http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01 <DIV></DIV>_______________________________________________ <DIV></DIV>Dev-cpp-users mailing list <DIV></DIV>Dev...@li... <DIV></DIV>TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm <DIV></DIV>https://lists.sourceforge.net/lists/listinfo/dev-cpp-users <DIV></DIV></div><br clear=all><hr>The new <a href="http://g.msn.com/8HMHEN/2737??PS=">MSN 8:</a> smart spam protection and 2 months FREE* </html> |
|
From: <lis...@da...> - 2003-08-07 12:39:20
|
Hello dev-cpp-users; hello Per,
thanks for your reply! I didn't even know about extern (newbie at work ;)),
but now that I added it, everything works perfectly fine. Thanks again!
Your Message: (Wednesday, August 06, 2003, 1:29:05 PM)
PW> Are you compiling a c++ program? The jpeg library is in C. Did you
PW> remember to specify
PW> extern "C" {
PW> #include xxx
PW> }
PW> when including the jpeg include files?
PW> As you can see, the linker doesn't just complain about
PW> missing symbol _jpeg_std_error, but actually knows about what parameter
PW> types the function takes. This is because your source code is trying to
PW> call the jpeg functions in C++ mode, i.e. with name-mangled external
PW> references.
PW> /Per W
>> Thanks for your reply!
>>
>> Your Message: (Sunday, August 03, 2003, 10:51:28 AM)
>>
>> OB> Dennis Möhlmann wrote:
>>
>> >> Oops, didn't know the linker can any other error messages than this one (never
>> >> received a different error so far...)
>> >>
>> >> (hope this doesn't get wrapped...)
>> >>
>> >> g++.exe ../_obj/BlackMagic3D.o ../_obj/world.o ../_obj/entity.o ../_obj/engine.o ../_obj/model.o ../_obj/winmsg.o ../_obj/viewport.o ../_obj/keyboard.o ../_obj/renderer.o ../_obj/image.o -o
>> >> "..\_exe\BlackMagic3D.exe" -L"C:/Programme/Dev-Cpp/lib" -mwindows -lopengl32 -lglu32 -lglaux -lwinmm -ljpeg
>> >>
>> >> ../_obj/image.o(.text+0x68e):image.cpp: undefined reference to `jpeg_std_error(jpeg_error_mgr*)'
>> >> ../_obj/image.o(.text+0x6ad):image.cpp: undefined reference to `jpeg_CreateDecompress(jpeg_decompress_struct*, int, unsigned)'
>> >> ../_obj/image.o(.text+0x6c2):image.cpp: undefined reference to `jpeg_stdio_src(jpeg_decompress_struct*, _iobuf*)'
>> >> ../_obj/image.o(.text+0x6d6):image.cpp: undefined reference to `jpeg_read_header(jpeg_decompress_struct*, int)'
>> >> ../_obj/image.o(.text+0x6e8):image.cpp: undefined reference to `jpeg_start_decompress(jpeg_decompress_struct*)'
>> >> ../_obj/image.o(.text+0x7f0):image.cpp: undefined reference to `jpeg_read_scanlines(jpeg_decompress_struct*, unsigned char**, unsigned)'
>> >> ../_obj/image.o(.text+0x828):image.cpp: undefined reference to `jpeg_finish_decompress(jpeg_decompress_struct*)'
>> >> ../_obj/image.o(.text+0x83a):image.cpp: undefined reference to `jpeg_destroy_decompress(jpeg_decompress_struct*)'
>>
>> OB> Well, it sais, it has undefined references of jpeg functions.
>> OB> I have no idea though why it has them, as the jpeg library has these
>> OB> functions.
>> OB> Maybe you should try to recompile the jpeg library from the code.
>>
>> OB> --
>> OB> Greetings,
>> OB> Balázs
>>
>> --
>> Best regards,
>> Dennis mailto:lis...@da...
--
Best regards,
Dennis mailto:lis...@da...
|
|
From: w.y. <yok...@be...> - 2003-08-07 09:47:41
|
FerretallicA wrote:
>
> Still no luck. This is a f**king nightmare. Mayhaps a different approach...
> instead of asking who has a solution to getting it working, how about I ask
> this- put your hands up if you have DirectInput working in DevC++ 4.x... am
> I the only one having problems with it?
I copied and pasted from the examples from my book and got something
working. This uses Direct Input to read the mouse. It would take some
more tweaking to get something more useful, but this is something
at least. Assuming you have some basic windows app with menu choices,
pick a menu choice to use and call the 3 functions like this:
initDImouse(MainInstance, hwnd);
readDIMouse(hwnd);
shutDownDImouse();
"MainInstance" is a global I'm using obtained from the HINSTANCE
you get from WinMain. "hwnd" you probably know..
Merge the code below with your app, or put in a separate file (you'll
need to make a header file). The only library I included was
libdinput8.a (and libwinmm.a for something else) and I'm using
DevC++ 4.9.8.0
This all compiles with no problem for me.
////////////////////////////////////////////////////////////////
#define INITGUID
#include<windows.h>
#include<windowsx.h>
#include<dinput.h>
#include<cstdio>
#include"DImouse.h"
LPDIRECTINPUT8 lpdi = NULL; // dinput object
LPDIRECTINPUTDEVICE8 lpdimouse = NULL; // dinput mouse
const int winWidth = 640;
const int winHeight = 480;
int initDImouse(HINSTANCE, HWND);
int shutDownDImouse();
int readDIMouse(HWND);
int initDImouse(HINSTANCE hinstance,HWND hwnd)
{
DirectInput8Create(hinstance,DIRECTINPUT_VERSION,IID_IDirectInput8,
(void **)&lpdi,NULL);
// create a mouse device /////////////////////////////////////
lpdi->CreateDevice(GUID_SysMouse, &lpdimouse, NULL);
// set cooperation level
lpdimouse->SetCooperativeLevel(hwnd, DISCL_NONEXCLUSIVE |
DISCL_BACKGROUND);
// set data format
lpdimouse->SetDataFormat(&c_dfDIMouse);
// acquire the mouse
lpdimouse->Acquire();
return 1;
}
int shutDownDImouse()
{
// first unacquire the mouse
lpdimouse->Unacquire();
// now release the mouse
lpdimouse->Release();
// release directinput
lpdi->Release();
return 1;
}
int readDIMouse(HWND hwnd)
{
DIMOUSESTATE mouse_state;
int mouse_x = winWidth >> 1,
mouse_y = winHeight >> 1, prevX=mouse_x, prevY=mouse_y;
HDC hdc = GetDC(hwnd);
do
{ // get the input from the mouse
lpdimouse->GetDeviceState(sizeof(DIMOUSESTATE), (LPVOID)&mouse_state);
// move the mouse cursor
mouse_x += (mouse_state.lX); // relative movement
mouse_y += (mouse_state.lY); // returned....
// test bounds
// first x boundaries
if (mouse_x >= winWidth) mouse_x = winWidth-1;
else if (mouse_x < 0) mouse_x = 0;
// now the y boundaries
if (mouse_y >= winHeight) mouse_y= winHeight-1;
else if (mouse_y < 0) mouse_y = 0;
// Update output if changed
if ( (prevX != mouse_x) || (prevY != mouse_y) )
{
prevX = mouse_x; prevY = mouse_y;
char strbuf[250];
sprintf(strbuf,"Right click to exit. Direct Mouse: %3i, %3i
",mouse_x, mouse_y);
TextOut(hdc,10,20,strbuf,strlen(strbuf));
}
} while ( !mouse_state.rgbButtons[0] );
ReleaseDC(hwnd,hdc);
return 1;
}
|
|
From: FerretallicA <fer...@ho...> - 2003-08-07 07:34:40
|
Oo oi, Still no luck. This is a f**king nightmare. Mayhaps a different approach... instead of asking who has a solution to getting it working, how about I ask this- put your hands up if you have DirectInput working in DevC++ 4.x... am I the only one having problems with it? Cheers, -FerretallicA |