51,593 Topics

Member Avatar for
Member Avatar for JoBe

Hello ladies and gents, I just wanted to see what this small programs does so I tried it in Dev-C++ and in VC++ 2005, thing was, it worked in Dev-C++ but not in VC++ 2005 in which I got an error stating the following: [QUOTE]error C2664: 'MessageBoxW' : cannot convert …

Member Avatar for WolfPack
0
670
Member Avatar for coopedw

I know there are tons of posts on this, I think I'm on the right track with this, but I can't quite get it to work. I can't figure out how to get the range of primes to print. I'd appreciate any input I can get, sorry about the indenting. …

Member Avatar for bumsfeld
0
221
Member Avatar for JoBe

Hello ladies and gents, Ive downloaded the first four PSDK-FULL files and wanted to install these, but I don't know how exactly to do so. I tried to use winzip and extract them, but keep getting an error that says, failed to launch file: C\Documents and Settings\Johan Berntzen\Local Settings\Temp\install\setup\PSDK-x86.msi I …

Member Avatar for JoBe
0
187
Member Avatar for ray54

Help! I'm writing a program using Borland C++ Builder version 5.0 with a large number of ComboBoxes (about 120). I'm trying to use ComboBox in a "for" loop to set the ItemIndex of each box to the values in a specific array. Example Code: ... ... for (x=0;x<120;x++) { ComboBox[x]->ItemIndex=array[y]; …

Member Avatar for WolfPack
0
111
Member Avatar for lette

I've been working on this program all day and I'm so lost please help! I need to have a class that uses a 40 element array that has predicate function IsEqual, IsGreaterThan, etc and with member functions input, output, add, subtract. Is there anyway I can make this code smaller? …

Member Avatar for Bench
0
158
Member Avatar for comwizz

How are functions returning reference used?? Do they return values on the left side or the right side of the assignment. I would be glad if I could get some help. Thanks, comwizz.

Member Avatar for Bench
0
157
Member Avatar for tyczj

im trying to make a table using askii art thats changed when the dimensions of the array are changed. i have been playin it for like 2 hours and i cant figure it out, here is was i have so far. my definitions [CODE]#define M char (197); #define U_L char …

Member Avatar for tyczj
0
156
Member Avatar for Jon182

Hey guys, I am in the process of a program that counts integers I can do this by looking for the int keywork and then incrementing a variable although if an integers are implemented as: int j,k,l; I am not sure how to count this as 3 ints, I know …

Member Avatar for Jon182
0
451
Member Avatar for jcrcarmo

Hello to all, When I'm running my application from the debug folder, I'm able to save changes to the database, but when I load the Crystal report to display that data, it still displays the old data, i.e., the data before the changes. Does it have anything to do with …

0
100
Member Avatar for rgrwalker

This is what I have thus far. [code] # include <iostream> using namespace std; double miles( double miles, double gallons, double mpg); int main () { const int ARRAYSIZE = 10; // fixed array with 10 items double miles[ARRAYSIZE]={240.5, 300.0, 189.6, 310.6, 280.7, 216.9, 199.4, 160.3, 177.4, 192.3}; double gallons[ARRAYSIZE]={10.3, …

Member Avatar for Narue
0
85
Member Avatar for Whodey

OK well ive been trying to get this..and its just not working the way it should work.... :cry: The this is i got the cin in there...to put the input up in the code but it wont find where the addreess is....like i should be able to say...Erics address is?...and …

Member Avatar for Narue
0
99
Member Avatar for jhdobbins

I must be missing something here. I am having trouble when I try to get an input. The numbers work fine, but once you get the correct answer, the area: [CODE]void tryanother() { char yorn; printf("Would you like to try another one? (y/n)\n"); scanf("%c", &yorn); if (yorn == 'y') getnum(); …

Member Avatar for Ancient Dragon
0
251
Member Avatar for pit_bull

i have a computer science project for which i am recreatin the game of hangman as "classmate" here is my code the problem is that the correct guess of the name is not shown as "you won" somebody please run this code and help it is done in tc++ so …

Member Avatar for agiorgio
0
110
Member Avatar for Jon182

Hey guys, I have the following two pieces of code and I am trying to combine them so it will say if hello is found and it is at the start or the prevous character is whitespace then add one to the count but when i try to combine these …

Member Avatar for agiorgio
0
189
Member Avatar for Mac Paul

please send me a program of SRTF using c++, using linked list... i'm realy spending days trying to do it but i cant get it right so i need a basis for me to do it my own....

Member Avatar for agiorgio
0
112
Member Avatar for Kiba Ookami

I messed with C++ my first year in programming, and now as an AP student its all Java focused. As I want to be a game programmer I decided to get back to learning C++ because I've heard its often used. So, I downloaded Bloodshed Dev-C++, which was reccomended by …

Member Avatar for Narue
0
115
Member Avatar for brianotieno

#include<iostream.h> class rectangle { protected: int lenght,widht,height; public: rectangle(){lenght=0;widht=0;height=0;}; void seta(int lenghti); void setb(int widthi); void setc(int heighti); int getlenght(); int getwidth(); int getheight(); }; class box:protected rectangle { private: int length,width,height; public: rectangle(){length=0;width=0;height=0;}; void setlenght(int lenght); void setwidth(int width); void setheight(int height); int getlenght(); int getwidht(); int getArea(); int …

Member Avatar for dwks
0
139
Member Avatar for DotNetUser

I'm coding in VC++.net (managed C++). Is there a way to create dynamic arrays and preserving the data when the dimensions are changed? I know that Visual Basic can do this. In VB: ReDim Preserve mLn(UBound(mLn) + 1)

Member Avatar for dwks
0
60
Member Avatar for Whodey

ok im stuck here atm...what im trying to do is to have the program compile to run in windows..and i have to type in the name...and the program goes into the database and finds the address and puts it onto the screen...just like an address book.. So heres my code..anyone …

Member Avatar for Whodey
0
131
Member Avatar for caseg

my program runns but it isnt coming out right, i need to have on the left side my input*.01*cash and on the right side the chas sequencing 1-20 the problem is the cash numbers are counting more than once before going on to the next number for example: 1 1 …

Member Avatar for Whodey
0
145
Member Avatar for smartravi

Hai I am new to VC++ and I am having x.dll which is developed in c#.NET . It consists of one interface and other classes. In that interface data member ( constants) defined and some funtion(method) definitions are there. Now I have developed an application in VC++ for that i …

0
69
Member Avatar for caseg

hi, i can figure out why this program keeps counting up the cash variable more than once when i run it, like it'll be 10 10 10 10 10 11 11 11 11 11 and the percentage numbers have the letter "e" at the end of each percentage... just seeing …

Member Avatar for Bench
0
106
Member Avatar for robase

I have an Amusement Park Problem in C++ > Category > Children > Price $2.00 > The first child is always free > Category > Youth > Price > $8.50 > For every 4 tickets in this group one person is free. > Buy 4,get one free > Category > …

Member Avatar for Bench
0
698
Member Avatar for candykane69

> Write a C++ program having a recursive function recursiveMinimum that takes an integer array and the array size as arguments and returns the smallest element of the array. The function should stop processing and return when it receives an array of 1 element. #include <iostream> int recursiveMinimum(int[], int); int …

Member Avatar for candykane69
0
99
Member Avatar for tyczj

im not sure how to write an assignment operator for a 3d array this is what i have bit i know its wrong [CODE]Cells& Cells::operator= (const Cells& cells) { resetSize(cells.DEPTH, cells.ROW, cells.COL); for(int d=0; d<DEPTH; d++) for(int r=0; r<ROW; r++) array[d][r] = **this for(int c=0; c<COL; c++) array[d][r][c] = cells.array[d][r][c]; …

Member Avatar for tyczj
0
167
Member Avatar for Mike182

Id like someone to take a look at this piece of code and tell me any errors to correct, ms-vc++ 6.0 says there are 3, but when I correct them it creates more errors (example being: going from 3 errors to 18 with one ';' going in) Help appreciated. Here …

Member Avatar for Ancient Dragon
0
334
Member Avatar for bg123

I have a program where the user enters a number and it prints all the prime numbers between 1 and that number. I have been able to do that. It must also print the max prime number, the greatest prime between 1 and that number. This is where I am …

Member Avatar for WolfPack
0
131
Member Avatar for javamum

This is the first program I am writing after taking one C++ class 4 years back. Please help me with this syntax error: #include <iostream> #include <math.h> using namespace std; enum run {TERMINATE=0, LOOP, NoRoot}; double f (double x); double f (double k); double f (double n); return (x*(1 + …

Member Avatar for javamum
0
99
Member Avatar for kryptolite

i'm trying to make a hangman game with c++ right now and i got a question: how do you get a RANDOM word from a text file? given there is only a word each line in that file e.g: television computer football butterfly etc. anyone can help? thx.

Member Avatar for AhmedHan
0
203
Member Avatar for magikman

Howdy, I have been trying to teach myself C++ for a few months now and have been progressing nicely thanks to all the wonderful help I have received on this site and others. Thanks for your help! Now, on to my question. I am currently trying to learn linked lists. …

Member Avatar for Rashakil Fol
0
497
Member Avatar for apcxpc

Hi all I am fairly new to C++, and am having problems creating a quick GUI application using the Win32 API. I'd like to use the "windows form project" option in Visual C++ ...which creates windows, textboxes, buttons etc. through a drag & drop interface. The problem is that I …

Member Avatar for WolfPack
0
131
Member Avatar for rgrwalker

I have the code written, compiling and no errors, I just need it to write to a file now. This is the code I have. Is the header piece correct? [code] #include <iostream> #include <string> #include <fstream> #include <cstdlib> using std::ofstream; using namespace std; class finalgrade { char firstName[20]; //to …

Member Avatar for Ancient Dragon
0
137
Member Avatar for tyczj

so im new to templates and i dont understand the errors im gettin in my code. the errors start where it says "sort double array" in the main and the errors are the same for all 6 function calls after that "cannot convert parameter 1 from double[10] to int []" …

Member Avatar for Rashakil Fol
0
135
Member Avatar for jcrcarmo

Hello everyone, Greetings from Brazil! As shown in the code below, is it possible for me to add the new objects for tipoDT and sementesDT without having to do it one-by-one? Like, for example, getting the values automatically from the tables?.... How would I do that? The sementesDT table is …

Member Avatar for jcrcarmo
0
171
Member Avatar for Acidburn

Hello, I've got a 2 diemsional array that ments to represent this: Name Address A 1 B 2 C 3 I've got the following code written for this: [code] char * tableArray[10]; [/code] should that be: [code] char * tableArray[10][10];? [/code] And I've got a pointer that populates only the …

Member Avatar for Bench
0
106
Member Avatar for jlouang

I need help making a program that include meter yards and feet. my c+ class is only in chapter 4 of the c++ book. function header should be void convertMeters(int meters) int main 1. ask for the number of meters 2. read in the number of meters 3. call your …

Member Avatar for jlouang
0
138
Member Avatar for rgrwalker

I can't seem to get it working properly. Here's what I have thus far. #include <string> #include <iostream> class Student_t { char firstName[20]; //to hold the first name char lastName[20]; //to hold the last name int exam1; //to hold Exam-1-Grade int exam2; //to hold Exam-2-Grade int homeworkavg; //to hold Homework-Average …

Member Avatar for rgrwalker
0
242
Member Avatar for janito2008

I need help with a program for school. I have to write a program that asks for the number of days each employee is absent, the total number of days absent for all employees combined and the average number of days absent for all employees combined. I need help before …

Member Avatar for Bench
0
807
Member Avatar for niceguy21

1. The temperature of a city is obtained at a weather station in degrees centigrade. The job is to convert this temperature into its corresponding value in degrees Farenhiet. Assume the data type for the value of temperature to be 'double' and use the formula F=(9/5)*C+32. What is the input …

Member Avatar for Bench
0
143
Member Avatar for Whodey

hmm im trying to convert this over..so that i can right the name in the program and it finds..the address in the database....i think im on the right track just some problems...any help or tips? [CODE]#include <map> #include <string> #include <iostream> using namespace std; int main() { map<string,string> addressbook; pair<string,string> …

Member Avatar for Ancient Dragon
0
129
Member Avatar for jcrcarmo

Hello everyone, Greetings from Brazil! Please help! I have a DataGridView in a windows form with three columns: Column1 is TipoComboBoxColumn Column2 is QuantidadeColumn Column3 is SementeComboBoxColumn I need the SementeComboBoxColumn to display values according to the value I select in the TipoComboBoxColumn. How do I go about accomplishing that? …

0
120
Member Avatar for Jon182

Hey guys I am just wondering why the following code gives the wrong number of characters from a file when the character count is the default? Thanks. [code] void main() { int blank_count = 0; int char_count = 0; int sentence_count = 0; char ch; ifstream iFile("c:\test.txt"); if (! iFile) …

Member Avatar for Jon182
0
71
Member Avatar for paulotara

I would need a quick implementation in C++ on how to trap and manipulate keyboard events probably thru keyboard hookin reply on [email]paulotara@yahoo.com[/email] :mrgreen:

Member Avatar for Acidburn
0
91
Member Avatar for comwizz

Hello everyone, I was having this problem of sorting words of a string entered by user where the user enters many strings and words of each string are sorted separately. This had to be done using pointers . Heres my attempt.I dont know where I am going wrong as garbage …

Member Avatar for HackWizz
0
355
Member Avatar for khot_anuradha
Member Avatar for agiorgio
0
368
Member Avatar for JoBe

Hello ladies and gents, I wanted to ask if any of you could tell me what I'm doing wrong when I want to debug any program that Ive written in VC++ 2005 Express Edition. Reason is, after I put a break point to where the program has to run and …

Member Avatar for JoBe
0
205
Member Avatar for thehakan

Hi everybody; I just started to learn stacks. How can I count the number of Items in a stack by using ADT stack operations?? Can u help me?

Member Avatar for thehakan
0
184
Member Avatar for 111Help

Can someone offer assistance in converting seconds to minutes and seconds. :?:

Member Avatar for Lerner
0
124
Member Avatar for stackOverflow

Hi, These are some of the few questions for which i couldn't find answers. :lol: . I was just hoping if any of you can help me out. 1.Write a "Hello World" program in 'C' without using a semicolon. 2.Write a C++ program without using any loop (if, for, while …

Member Avatar for Bench
-1
320
Member Avatar for kharri5

I am trying to do a priority queue with a custom type, but I keep getting this error des.cpp:77: error: expected init-declarator before "eventQ" des.cpp:77: error: expected `;' before "eventQ" This happens in the following code [CODE] Program: This is a discrete event simulator designed to aid in the analysis …

Member Avatar for kharri5
0
389

The End.