49,761 Topics

Member Avatar for
Member Avatar for Mac.Z

Hi everyone, Sorry for the long title! What I want to know is whether it's possible to convert specified elements of array of char to int using some fuction ? let's say we have char x[10], x[0] = '9', x[1] = '2' so I want to have 92 in a …

Member Avatar for WaltP
0
80
Member Avatar for ghadahelal

is there is any fun in the c++ library that takes a dec and return hex

Member Avatar for WaltP
0
216
Member Avatar for sInFuL69er

Hello, iam having trouble with reading a text file that contains , [ ] eg. 3715,4[9] 4356,3[7,3] [code] char c; int events[12][12];//[row][col] ifstream infile; infile.open("test.txt"); while (!infile.eof()) { for(int j=0;j<12;j++) { for(int k=0; k<12;k++) { if(c!=']') { infile >> events[j][k]; infile.get(c); } else events[j][k] = -1; } } infile.get(c); } …

Member Avatar for WaltP
0
97
Member Avatar for mathgirl

I am trying to write a program that will prompt the user for six grades to be entered (one at a time), read in each grade entered by the user, and store them in an array of six elements. Grades should be on a 0 to 4.0 (inclusive) scale, and …

Member Avatar for ndeniche
0
111
Member Avatar for rockthrower

Hello, I am trying to read data from a text file in the following format: 05 mike smith 30.00 2 1 so the format is: int, character[21] = max size of array, double, int, int I am trying to read the values into an array of objects. I can read …

Member Avatar for WaltP
0
242
Member Avatar for squinx22

Hi gud day! Anybody who knows how to save a file to [U]/usr/include[/U] in the terminal? Suppose I will save a file named hello.h to the said directory, what would I do in the terminal? thank you very much....

Member Avatar for ndeniche
0
90
Member Avatar for Covinus

[code] a=(char*) malloc(sizeof(15)); b= bmfh.bfType; sprintf(a, "bfType: %d", b); TextOut (hdc, 0, 0,a , strlen(a)) ; delete[] a; a=(char*) malloc(sizeof(15)); b=bmih.biBitCount; sprintf(a, "bitCount: %d", b); TextOut (hdc, 0, 20,a , strlen(a)) ; [/code] is it necessary to leave the a undeleted when i gave it another value or i should …

Member Avatar for Covinus
0
113
Member Avatar for Covinus

what is the equivalent of javas repaint() method to win32s? i was now able to load a bitmap into a window but sadly you have to minimize or maximes the window before the bmp appears. any suggestions how to solve this one?? any help with be greatly appreciated.. thanks

Member Avatar for Covinus
0
72
Member Avatar for ghadahelal

hi all, i have a caputure file ( *.cap) i open it in binary mode , now i nead 2 make an outfile , also *.cap i gave the outfile 2 my prog. out.cap, it works and i became no errors, but when i tried 2 open it , it …

Member Avatar for ghadahelal
0
105
Member Avatar for MarzenaM

I have to write programm to sort numbers from in ascending order, using vector (C++ language) I did this using array, and it works perfect. Please could you help me replace array to vector. It's very urgent. :'( My code is: [code=c] #include <iostream> void fill_array(int a[], int size, int& …

Member Avatar for Lerner
0
110
Member Avatar for Tauren

Greetings! I just have a question is the book C++ Programming Primer By D.S. Malik a book worth getting? What stage is it: Beginner, Professional What does it teach me up to: What the last topics in book Will I need more books after this regarding the topic? And is …

Member Avatar for Narue
0
264
Member Avatar for amitmistry_petl

Can any body help me ???? i face a critcal problem with [B]AtlWaitWithMessageLoop(hThread);[/B] will actually I don't know much about threading. but when I put my main thread in wait at that time workerthread will not able to post the message (SendMessage() ) to the Mainthread I know That it …

Member Avatar for Ancient Dragon
0
313
Member Avatar for jaepi

hello there, in what way you can convert an integer to a char?? i'll use it to check if the user's input is a number, if it is a letter, it will allert him to try again and input a number...the integer will then be use for a 'for loop...thanks

Member Avatar for WaltP
0
160
Member Avatar for MarzenaM

[B]Hi I need to create a void function to calculate area and circumfernce of triangle.[/B] [B]So far I did this:[/B] void area(int a, int b, int c ) { using namespace std; int area; int circ; int s; s = ((a + b + c)/2); if ((a + b > …

Member Avatar for WaltP
0
252
Member Avatar for minigweek

I recently started dabbling with Visual C++ Express Edition 2005. Was stuck at the very onset! LOL! How to Create a console application using Visual C++ Express 2005 ?? I could create the project, included the files..did all.. build it nice and clean.. but how to run [ make ] …

Member Avatar for minigweek
0
190
Member Avatar for parthiban

Hi all, I tried one program to understand the concept of "Default Arguments" that program works prefectly in Dev C++ but not in Turbo C++ compiler(Ver 3.0). Here's my program [code]#include <iostream.h> #include <stdio.h> using namespace std; void justcall(char *c="Parthiban"); //char a[10]; //Global declaration needs for Turbo C++ Compiler void …

Member Avatar for parthiban
0
116
Member Avatar for m3an

its part of a dvd program. i want all the objects created and manipulated by the program to be stored in a dynamic array that might grow during the execution of the program. I want to program to store the info in a dynamic array that i can call anywhere …

Member Avatar for m3an
0
146
Member Avatar for somita1

i use from file (text file)for take word of file i must pass space but i dont knw it and for goinnig to next line in file what do i?

Member Avatar for Ancient Dragon
0
128
Member Avatar for rapperhuj

i want my program to have a listbox item with 10 choices.. what would be the code..?? and i want to change the icon at the header bar.. Thnks for reading and giving some advice and code hint..;)

Member Avatar for ~s.o.s~
0
55
Member Avatar for louis7370

why my program don't execute? [code=c] void Supplier::AddDetails() { char ch='y'; int end; fstream suppauto; suppauto.open("Supplier.txt",ios::app); suppauto.seekg(0,ios::end); while (ch=='y') { char s[12]; system("cls"); cout<< " Adding Supplier Details"<<endl; cout<<" ****************************************"<<endl<<endl; suppauto.seekg(0,ios::end); end=suppauto.tellg(); if (end==0) { suppauto.close(); strcpy(suppcode,"S0001"); } else { suppauto.close(); for(int i=0;i<6;i++) suppcode[i] = '\0'; fstream suppauto1("Supplier.txt",ios::in); while(!suppauto1.eof()) { …

Member Avatar for Salem
0
136
Member Avatar for xaphan

help wid few things: -exit function -check if one wins -cannot enter in an occupied place... i would be thankful! [code=c]#include <iostream> #include <string> using namespace std; int main() { string a = "1"; string b = "2"; string c = "3"; string d = "4"; string e = "5"; …

Member Avatar for Lerner
0
80
Member Avatar for faiz

i have to make a project for the course of object oriented programing (C++).can any one give a suggest any topic? the project should be able to be completed in a period of two months.

Member Avatar for mariocatch
0
51
Member Avatar for parthiban

Hi all, I just started to work C++ in Dev C++ compiler before that i used Turbo C++ compiler when i try to compile a simple program in Dev C++ compiler . I'm getting error . Here's the program [code]#include <iostream> #include <conio.h> int main () { cout << "Hello …

Member Avatar for parthiban
0
671
Member Avatar for Slavrix

Hey guys, im just askign if its possible for sum help with this assignment i have, its a connect 4 game, and there are some bugs that i cant work out of it no matter what i try here is the code. problem are: 1. when choosing from the first …

Member Avatar for Slavrix
0
131
Member Avatar for kylcrow

I am a freshman in college, and I am a computer science major. I am looking to co-op/intern this summer and fall, and I was wondering what a good entry level job would be, like thier duties and responsibilities. I am posting here becuase I know more about c++ then …

Member Avatar for kylcrow
0
91
Member Avatar for Escom

Let's determine a t square matrix's column, which elements' sum, above the main diagonal, is the biggest! Any idea how i should start this in c++?

Member Avatar for Lerner
0
107
Member Avatar for jaepi

hello there...i've been using this function to know if the input of the user is a number or a letter...but it's not working... [code] #include <iostream> #include <math.h> using namespace std; double temp2; int main(){ cout << "\n enter something"; cin >> temp2; if(isnan(temp2)){ cout << "not a number \n"; …

Member Avatar for thekashyap
0
115
Member Avatar for MarcosEdu

Hi guys, I startin the project of a (web) server in c++ and i want to able to manage about 1000-2000 clients. I have been reading alot about Single-thread VS Multi-thread server and i wanna know what u guys think about it. I do not plan on using one-thread-per-client because …

Member Avatar for MarcosEdu
0
310
Member Avatar for kylcrow

How would one right justify a string with a width of 4 and store it in a variable without being able to use cout? If that is even possible.

Member Avatar for Narue
0
142
Member Avatar for nkhosinathie

hello everyone. i'm developing a program from a department-store customerhas exceeded the credit limit on a charge account.for each of the following facts are available.account no,balance of the begining of the month,i total of all items charged by this customer,total of all credit applied to this customer.'m required to instal …

Member Avatar for Ancient Dragon
0
164

The End.