49,761 Topics

Member Avatar for
Member Avatar for jov0708

i wrote a code to get hard disk info and used FindFirstVolume(). however, the console-based application was ok but when i made an MFC application doing the same thing, it did not compile correctly. i think the problem is with my redeclaration of _WIN32_WINNT in the MFC application. this is …

Member Avatar for jov0708
0
495
Member Avatar for linux0id

Hello everyone! I am new to C++. I am learning GUI programming using gtkmm on linux. I have a frame class, and I have a library class (that writes data to sqlite) that belongs to that frame. How should I declare it - by pointer or reference? like - [CODE]class …

Member Avatar for linux0id
0
88
Member Avatar for Darko

hey all :cool: !! me a new member here.. jsu joined up a couple of weeks back.. anyways peeps me is in fy B.E .CSE .. tho i am not a good programmer i dunno y i took it up... but i still like it... :D as all do i …

Member Avatar for jkertel
0
158
Member Avatar for boyet1970

hey guys im new here can anyone teach how to start.(cus i want to learn c++ programming how will i start).

Member Avatar for TimeFractal
0
108
Member Avatar for VIcissitude24

[code=c++] #include <fstream> #include <iostream> #include <string> using namespace std; string getFileName(); int numCharsInFile( ifstream &in, int &nLines ); int numWordsInFile( ifstream &in, int &nWords ); main () { int nLines, nChar, avgCPL, nWords; ifstream textFile; string fileName; fileName = getFileName(); textFile.open(fileName.c_str()); if(!textFile.is_open()) { cerr << "Cannot open file: " …

Member Avatar for superjacent
0
118
Member Avatar for tones1986

Hey folks - i am working on an assignment for school and would like some input if possible. I am trying to declare a class object in the form of an array so that i can read info from file and then manipulate the data. I need 3 seperate c++ …

Member Avatar for vmanes
0
204
Member Avatar for chubbywubba

I need help with the assignment operator and destructor, and the deleting by copy. Can someone help me with this? and when i compile just this i get an error on line 219 saying term does not evaluate to a function taking 0 arguments. Does anyone know what this means …

Member Avatar for Ancient Dragon
0
97
Member Avatar for k2k

I am trying to search an array of object, for example lastName, a private variable of the object, however, the array might have more than one same last name from different objects.. i need to output all the same last name onto the screen, how should i do that? code …

Member Avatar for Ancient Dragon
0
95
Member Avatar for Majestics

i Dont have window.h header file , can i make a programme for copying picture from one drive to another?Any one help me in interpets . I am new using c++ so please please help.

Member Avatar for Nick Evan
0
121
Member Avatar for abrou

Hello! I'm compiling a project in VC++ 2005 express, and for some reason it is hanging. It gets to a certain point and just doesn't seem to do anything. This is the readout when it is happening: [CODE]c:\Qt\4.3.3\bin\uic.exe RoboSearch.ui -o ui_RoboSearch.h g++ -c -O2 -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT …

Member Avatar for abrou
0
114
Member Avatar for faisaly

Can over running of array lead to the catastrophic failures? If ‘Yes’ then why does not C++ provide bound checking on array operations and who is responsible to prevent array overruns?

Member Avatar for vijayan121
0
290
Member Avatar for gReen_aXe

[CODE]#include <iostream> using namespace std; typedef struct List { int data; List*link; List(){ data=0; link=NULL;} }SList; SList*L,*P,*temp; int x; SList*createnew(int x){ temp=new List; temp->data = x; temp->link = NULL; return (temp); } SList*findLast(SList*L){ temp=L; while(temp->link != NULL) temp=temp->link; return (temp); } void printList(SList*L){ temp=L; while(temp!= NULL){ cout<<temp->data<<endl; temp=temp->link; } } …

Member Avatar for Narue
0
149
Member Avatar for sid_arth2020

Ques. Write a function which prints the cards which are missing from a set of playing cards.Cards are represented in the form of string whose first letter represnts type and second is the card number. S-1=one of pade S-A=A's of spade C-k=King of clubs H=j=jack of Hearts....so on

Member Avatar for Nick Evan
0
72
Member Avatar for Han1977

I know this might be a stupid question. I was trying to make a game with allegro for fun but it getting longer and longer after a while. Now I know I should divide my project to several files instead put all the code at main.cpp. But how to do …

Member Avatar for Ancient Dragon
0
84
Member Avatar for Adrian99420

Hi, I am currently doing a project which need to read the IMSI number from simcard and change the default setting of MotorolaZ8 for different operator. For example, the phone will automatically change the wallpaper setting after it detected certain operator's simcard is inserted. I would like to know whether …

0
60
Member Avatar for Heeyriss

Who can help me with this programming assignment about the token stream, character stream, source stream. And even tokenizer program? Please help me with this lexer program.. Thanks in advance...

Member Avatar for Killer_Typo
0
89
Member Avatar for technogeek_42

who can help to debug this analog program [CODE]#include<stdio.h> #include<math.h> #include<iostream.h> #include<conio.h> #include<graphics.h> #include<stdlib.h> #include<dos.h> #include<string.h> //CLOCK CLASS class clock { int h,m,s,thetamin,thetasec; struct time t; public: void time(); }; void clock::time() { int x=540,y=280,r=200,i; char n[12][3]={"3","2","1","12","11","10","9","8","7","6","5","4"}; struct REGPACK reg; setcolor(15); circle(x,y,88); circle(x,y,89); setcolor(6); settextstyle(5,0,1); for(i=0;i<12;i++) { if(i!=3) outtextxy(x+(r-132)*cos(M_PI/6*i)-8,y-(r-132)*sin(M_PI/6*i)-16,n[i]); else …

0
41
Member Avatar for kartik14

When I compile and run my programs in Dev C++, the output window opens and shows the output. Then instanlty the window flashes and disappears. How do I make the window stay long enough for me to read the output?? Thanks

Member Avatar for Duoas
1
13K
Member Avatar for NorseMN

I am developing a framework to simplify creation of embedded software applications. Resources are typically limited in this type of environment, so I need to make it very efficient in its use of memory space. One goal is to be able to reference any variable by a <typeNumber, instanceNumber> value …

Member Avatar for Ancient Dragon
0
1K
Member Avatar for Run.[it]

I have been given a project to do for college and have the option of doing it in either C++ or Java; both languages Im relatively new to. The scope of the project is fairly open ended, some are planning to do games but Im personally just going to do …

Member Avatar for John A
0
112
Member Avatar for Swoogles

Hi, I'll try to describe what I'm looking for as best as I can. I'm working on a dual monitor setup and I'm trying to really use the space that I have. I want to know if it's possible to use an editor (preferably vi, vim, or gvim) while I'm …

0
48
Member Avatar for abrou

Hello, I am a fairly inexperienced programmer, and I am confusing myself. I want to have a member function or a different class return an array of structures. I've read that I have to do this by reference, but I can seem to get it right. Can someone help? The …

Member Avatar for John A
0
108
Member Avatar for juan.s.duarte

I am having a problem writting a function to remove all occurences of a specific (user defined) integer from an array. Here is what I have so far. [CODE] #include<iostream> using namespace std; void menuDisplay(int& menuSelect); void remove(int intArray[], int& sizeOfArray, int removeItem); void removeAt(int intArray[], int& sizeOfArray, int index); …

Member Avatar for vmanes
0
201
Member Avatar for sjcomp

I have shared pointers to an interface created through out the program. I also have a list of weak pointers to their implementations in order to call internal update function. The program works, but when I compile it I get warning C4180. The question is, how to get rid of …

Member Avatar for sjcomp
0
244
Member Avatar for sid_arth2020

Ques.Definition of priority queue was given. We have to implement the priority queue using array of pointers with the priorities given in the range 1..n. The array could be accessed using the variable top. The list corresponding to the array elements contains the items having the priority as the array …

0
64
Member Avatar for sid_arth2020

Hi iam working on a problem given to me by my teacher.The problem is !.People from different states send their application to participate in the dance competition organised at the country level.Only 30 people will be selected to take par in the competition.Participants will be selected randomly from one state.No …

Member Avatar for plgriffith
0
76
Member Avatar for asifakram

hey...i am new to this site and also new using visual c++...and i need help in a project! i am asked to find prime numbers using for loop ! i cannot figure out how to write the program. please help sumone! i desparately need it within 4 hrs !! please. …

Member Avatar for plgriffith
0
159
Member Avatar for tedobg

You guys helped me a lot last time I posted so now that I have trouble i again turn to you :).Ok can someone tell me with what can I substitute the following code.It is supposed to get some lines and put them in strings. [code] system("cls"); string user,date,title,description; cout<<"Please …

Member Avatar for carnage
0
104
Member Avatar for Grub

I am writting a program that makes use of a vector of objects. Every time I add an object the windows system encounters a problem and needs to be closed. [code=c++] #include<iostream> #include<fstream> #include<string> #include<vector> using namespace std; class Catalogue { public: string vendor; string item; float price; int code; …

Member Avatar for Grub
0
95
Member Avatar for honeyS

Pls show me the code on how to press ESC key automatically without pressing the keyboard.. Thank you!

0
58

The End.