49,757 Topics

Member Avatar for
Member Avatar for luoleicn

Hi all I am trying to add GNU adns to my project, But ands thew an error "Assertion `ads->udpsocket >= 0' failed" after running for 10 minuntes. Anybody here met this before? I use ands as follow: [ICODE] bool DnsResolver::resolve(const char* domain, char ip[]) { bool result = false; adns_state …

0
45
Member Avatar for fadia

heey guys.. i'm trying to run this pro but i have one error.. can someone check it please. [CODE=language]#include <iostream> #include<cstdlib> void JOTAKU_LOGO (); //This function calls the flight agency's Logo. void ABOUT_JOTAKUAIR (); //This function displays a briefe history and information about J-Otaku Air. double DOLLAR_TO_YEN (double dollar_Z); //This …

Member Avatar for achied
0
298
Member Avatar for nustian

dear all, I have made a project in visual c++ and now i want to give a graphics user interface to my code. what is the easiest and effecient way to do so. Is there any software which can convert my code? reply.. regards

Member Avatar for William Hemsworth
0
47
Member Avatar for slawted

hello, first of all welcome, secondly someone please help me? this wont compile :( [code] #include <iostream> int main() { float pi; float radius; float area; pi = 3.1415926535; radius = 2; area = radius * pi; std::cout << "The area of a circle with a radius of 2 is …

Member Avatar for slawted
0
96
Member Avatar for meb111

Hi i would like to know, how can i get the color of a certain pixel on screen? Like when i am in a game and i press a button on the keyboard it will get what color it is in one specified pixel say... (100, 50) Thank you so …

Member Avatar for meb111
0
73
Member Avatar for Lukezzz

I have a little problem that my Form gets stuck when I run this first code. I have a lot of code in the event. The code runs fine but if I now will deactivate the form by clicking with the mouse on the desktop and again click somewhere on …

Member Avatar for Lukezzz
0
97
Member Avatar for themaster

Does anyone know how to give a GUI look to your C++ "Console Application". I cannot use Win32 API or any other template except the console application because I use Turbo C++ 3.0 IDE for development and I want my Application to be platform independent while using WIN32 API will …

Member Avatar for Ancient Dragon
0
290
Member Avatar for chaines51

I'm wondering if this is even possible in C++. Here's what I did in java a while back: [code=java] class Suit { public static Suit Hearts = new Suit("Hearts"); public static Suit Clubs = new Suit("Clubs"); public static Suit Diamonds = new Suit("Diamonds"); public static Suit Spades = new Suit("Spades"); …

Member Avatar for ArkM
0
162
Member Avatar for star34

Hi im working with linked list and i have to implement a function that deletes the duplicates of a number. for example if given 2 7 1 7 12 7 then the result should be 2 7 1 12 here is what I have: [code] #include <iostream> using namespace std; …

Member Avatar for NeoKyrgyz
0
111
Member Avatar for DonB

I'm using Borland's TurboC++ 2006 Explorer. I'm working on a class project, and have a program consisting of 3 files: [COLOR="Red"]Header (.h) Definitions (.cpp) Driver (.cpp)[/COLOR] [COLOR="Red"]Definitions.cpp[/COLOR] contains the typical [COLOR="Red"]#include Header.h[/COLOR] The program compiles and links correctly if [COLOR="Red"]Driver.cpp[/COLOR] contains the statement [COLOR="Red"]#include Definitions.cpp[/COLOR] The instructor doesn't like using …

Member Avatar for DonB
0
161
Member Avatar for Usura

how would i remove all the white space from an istream and replace them with "-" before producing an ostream?

Member Avatar for Ancient Dragon
0
788
Member Avatar for gnobber

I've read that the bits in a byte (in c++) are implementation or system dependent. What does that mean? Does it mean implementation of c++ or the processor architecture or some other thing? And I've read that you should use sizeof to determine the size of a byte? Could you …

Member Avatar for DonB
0
317
Member Avatar for Usura

Hey what would be the correct syntax for a vector of char* with a size of [2]? ive got it written like this.. vector< char* > myVector(); vector< char* > ::iterator myIterator; // reads in something myVector.push_back(temp); myIterator = myVector.begin(); cout << myIterator << endl; why does it cout nothing?

Member Avatar for William Hemsworth
0
96
Member Avatar for yun

I want to read and write string from file, - Dont want to overwrite on the existing file - Where to put the read file code as in Constructor if file is not created then it will generate error. help me to solve this issue. [code=cplusplus] class Security{ private: Map<string>password; …

Member Avatar for Stinomus
0
241
Member Avatar for OffbeatPatriot

I'm writing code to control a camera and I'm using boost threads to repeatly get the camera image and write it to a gui among a few other things while everything else runs. It's written with wxWidgets and it has a menu with an option to open/close the link to …

Member Avatar for Stinomus
0
122
Member Avatar for AbsoluteCPP

Suppose i have a class called [B]Vector3[/B] methods and attributes are defined in [B]Vce.h[/B] file, methods of this class are implemeted in [B]Vec.cpp[/B] file, now i want to distribute this class to my other xxx(what so ever), [B]What i want:[/B] 1.Allow them to see what methods and attributes are available …

Member Avatar for WaltP
0
97
Member Avatar for JackDurden

IF i have this function... [CODE] node* get_lowest(node* root) { node* min = root->child[0]; for(int i = 0; i<root->child.size();i++) { if(min > root->child[i]) min = root->child[i]; } cout<<"Here it is:"<<min->data<<endl; return min; } [/CODE] how do I get it to return the smallest indexed pointer? for example if root->child[0] and …

Member Avatar for VernonDozier
0
253
Member Avatar for mrcniceguy

i have just started learning C++,this is my first programming language. but i was solving some question in array,but this one was a problem to me. here it goes. create array,in that array find sub arrays(subset), in which there is a maximun number in increasing order. for example array below …

Member Avatar for mrcniceguy
0
111
Member Avatar for abhishekmadaan

Hi, I am making a program in which i need to append the file from the beginning. so i am opening the file like this wFile.open("sat.txt",ios::ate| ios::out | ios::in); moving the pointer to the beginning wFile.seekp(0,ios_base::beg); but when i try add data it is overwriting the data. Is there any …

Member Avatar for ArkM
0
92
Member Avatar for Lukezzz

I have made a form that contains about 60 buttoncontrols, 7 panels and 10 textboxes. What happens when I drag around this Form etc.. is that the controls flickers very much. How is it possible to reduce this flickering. Thank you...

Member Avatar for Lukezzz
0
78
Member Avatar for chaines51

I've always been curious: in VS, and most other IDEs, you are allowed to do something like this: [code=c++] //in file class.h class blah { //prototypes, members, blah, blah blah } //in file class.cpp #include "class.h" //method definitions... etc. //in file main.cpp #include "class.h" int main { //do stuff with …

Member Avatar for VernonDozier
0
115
Member Avatar for schnaiper

Hi I work on a anti-virus programm. The anti-virus program should start when you boot the computer. So I thought it is good to use a HKey to start it always. How can I make such a HKey which starts my program? thx

Member Avatar for schnaiper
0
69
Member Avatar for yun
Member Avatar for Mijchael

) Hi Guys, I am working now in a project that is placed into my docs\visual studio proj, that need to use . h files, placesd in c:\prog files\windows sdk and c:\prog files\OpenCv. Into these directories have another subdirectories with these .h that into them are included others .h files …

Member Avatar for Ancient Dragon
0
99
Member Avatar for ahspats

so my program has to read data from text file and pass it to the function. text file contains integer and string in every line. it looks like this: 23456 john 96512 martin 56985 wendy i've written it in C using this code: while (fscanf(filestream, "%d%s", &key, &value) == 2){ …

Member Avatar for csurfer
0
159
Member Avatar for aravasai

can any one please identify the mistake in my code??? my code is:: [code] #include<iostream> using namespace std; class Stack{ int *arr; int size; int top; public: Stack(){arr = NULL; top = 0;} Stack(int sz){ arr = new(nothrow) int[sz]; if(!arr) exit(1); size = sz; top = 0; } ~Stack(){delete []arr;} …

Member Avatar for Stinomus
-1
18K
Member Avatar for guest7

Hello, I am getting the follwoing error in my program: *** glibc detected *** free(): invalid pointer The program is as follows. [ICODE]int main() { operation1* sjob1 = new operation1(); answer* ans1 = sjob1->execute(); delete sjob1; operation2* sjob2 = new operation2(); answer* ans2 = sjob2->execute(); return 0; }[/ICODE] I have …

Member Avatar for Topi Ojala
0
199
Member Avatar for gretty

Hi I am making a rock, paper scissors game for fun & for practice. My problem is; I am trying to create a string by adding 2 character variables together. How do I do this? Do I use the insert function? Or something I think is called crstrt or something …

Member Avatar for jephthah
0
697
Member Avatar for bjanbkboi

I'm trying to read a file into a vector using structure...[CODE]#include <fstream> #include <iostream> #include <vector> #include <cstdlib> using namespace std; struct StudentRecord { int ID; char FirstName[30]; char LastName[30]; char Grade[1]; }; void read_file(char FileName[20],vector<StudentRecord> &students) { ifstream Students(FileName, ios::in); char S_ID[10]; /* char FName[30]; char LName[30]; char S_Grade[1];*/ …

Member Avatar for ArkM
1
106
Member Avatar for jazu100

Hi, to answer this question you need to have some experience about php... i'm planning to create a http server that supports cgi. Does anyone see the problem in C++ -source? Php doesn't give any output, but if I don't set the rfc3875 environment variables, all output comes normally (expect …

Member Avatar for ShawnCplus
0
832

The End.