49,755 Topics

Member Avatar for
Member Avatar for Jakiro

hi all. I have a question need your all help. 1.what is the problem for my delete function,I can't delete the list that i select(but no error in that case) 2.how to build the search function with that prototype? [code=cplusplus] #include <iostream> #include <string> #include <cstdlib> using namespace std; struct …

Member Avatar for Duoas
0
87
Member Avatar for zandiago

Good day to all of you who assisted me. I never thought I'd pass this class, but with all your help, I made it. This is the only C++ course that I needed...so I really wont have any c++ questions to post around here to bug anyone...but i'll still hang …

Member Avatar for zandiago
2
91
Member Avatar for maHvic

can you please help me how to make this program?? please... For VRC (Should all be contained in functions/methods/class) - Inputs > Message to be transmitted / Received Message should be captured in an Array (limited to letters, numbers and punctuations, as to: period, comma, exclamation point and question mark) …

Member Avatar for Salem
0
99
Member Avatar for gidos

im studying about Database with C++ support, i create a workspace for mfc dialog box, name of workspace is ABC. the source files of C++ is on C:\VCDb. I create on ODBC the System DSN name ab, the driver of this is Microsoft Access Driver. On abc workspace i #include …

0
55
Member Avatar for Ejl191

I'm trying to get my program to read from a text file, but the only way I'm able to get it accurate at the moment is to set the first loop to the number of lines of data that I have. I'm looking for a way to set it so …

Member Avatar for Ejl191
0
93
Member Avatar for jaepi

Hello there, do have any idea if there is a function that gets wchar from the stream, somewhat similar to fgets function. Thanks. :)

Member Avatar for jaepi
0
146
Member Avatar for jaepi

Hello there, is there a function in Linux that can handle the reading of an .ini file? Thanks.

Member Avatar for jaepi
0
1K
Member Avatar for qcwailun

I want to write a code for recording inventory item, all the functions work fine except the function for removing the data. I spend a lot of time in it but still cannot know what's wrong. Here is my code: [code=c++] #include <iostream> #include <fstream> #include <vector> #include <string> using …

Member Avatar for Ancient Dragon
0
270
Member Avatar for kaly12

This is a part of a c++ program: cout<< "Width:" << Width << "\n"; cout << "Length: " << Length << endl; what does the "\n" do in oppose to endl; ? also, when do you use void main instead of int main at the beginning of the program?

Member Avatar for invisal
0
88
Member Avatar for spankyg

Can someone please explain to me just exactly this try/catch is doing? It doesn't seem to make any sense to me. Thank you in advance. case '\r': if (Choice==(CancelIndex+1))return; try{(*Action[Choice-1])();} catch(...){} system("cls"); Choice = 1; break; case char(27): if ((CancelIndex+1)==ItemCount)return; try{(*Action[ItemCount-1])();} catch(...){} Choice = 1; break;

Member Avatar for spankyg
0
121
Member Avatar for Kattalyst

A College offers a course that prepares students for the state licensing exam for real estate brokers. Last Year, several of the students who completed this course took the licensing examination. Naturally, the college wants to know how well its students did on the exam. You have been asked to …

Member Avatar for Kattalyst
0
91
Member Avatar for guitarrick

I posted this one earlier, but no go......I'm getting an error for the constructor definition StudentRecord::StudentRecord() that it cannot return a value. This was running until I did some rearranging to try to get my function that calculates the total grade average in main to work.(So i commented that all …

Member Avatar for guitarrick
0
89
Member Avatar for r5ingh

Hello. I, the C++ noob is back again... This time requiring some help with some visual CPP. This is the first time im working with this, and its only @ a basic level. Yes, this is somehting im doing at university, but i dont ask for help unless im stuck …

Member Avatar for r5ingh
0
230
Member Avatar for volia

Hi guys, I'm new the site, in fact just stumbled on it looking for some help with some C++ strings. I'm taking 1400CS and well, to be perfectly frank, I'm not good at it. This is alright, I'm more of a VT person myself, but I have this and another …

Member Avatar for Narue
0
68
Member Avatar for comput_novice

i have a task how to link two files to read from oneanother like a search this is what i have please help this is urgently needed ofstream outfile; fstream myfile; outfile.open("Inventory.txt"); myfile.open("Invoice.txt"); outfile<< "\n\nWELCOME TO THE INVENTORY\n"; outfile<< "========================\n"; outfile<<"Item ID"<<setw(10)<<"Name"<<setw(16)<<"Descrition"; cout<<"Please fill in the following information\n\n"; cout<<"Item ID: …

Member Avatar for Salem
0
98
Member Avatar for kv79

Hi to all ,just a small question. When i read in the book for Win32 API tur. in c++, this: " cbSize The size of the structure. " I asked my self ,what sturcture? I tought we useing class.

Member Avatar for kv79
0
114
Member Avatar for __vmware__

Hello, I have problem witch i've been working on for a couple of days now with no real progress. The problem is that i'm trying to search trough a array of pointer for a certain value. If the value exist return that value to be used in another function, but …

Member Avatar for __vmware__
1
102
Member Avatar for eranga262154

Hi all, I have a string(not a CString), actually a file path. As an example, [CODE]c:\Test\MyProject\G00062_002_01.srf[/CODE] Then in following way get some data. [CODE] string FullPath = c:\Test\MyProject\G00062_002_01.srf string filePath = FullPath.GetFileTitle(); string groupID; string sessionId; string partID; groupID = filePath.substr(1, 5); sessionId = filePath.substr(7, 3); partID = filePath.substr(11, 2); …

Member Avatar for Duoas
0
112
Member Avatar for danbellinger1

I am working on a project using 2D arrays ( I have never really understood the use, I know how they work, just have always had problems implementing) that holds a 4x4 "magic square." Magic squares contain unique numbers whose rows, columns, and major diagonals add up to the magical …

Member Avatar for Lerner
0
166
Member Avatar for 3nCrypti0n

Im making this program. But im having trouble calling certain functions. Im having trouble calling ShellExecute, RemoveDirectory, CreateDirectory, FindFirstFile, & DeleteFile. I get the following errors when trying to compile... [CODE] c:\documents and settings\george\my documents\visual studio 2005\projects\mmpc v1.0\mmpc v1.0\prog.cpp(42) : error C2664: 'ShellExecuteW' : cannot convert parameter 2 from 'const …

Member Avatar for Duoas
0
215
Member Avatar for alcoheca

Hi, Despite triple checking my code for duplication and checking that the headers include #ifndef I still can't trace what is causing this error message: drawscr.o(.bss+0x0):drawscr.cpp: multiple definition of `massage' main.o(.bss+0x0):main.cpp: first defined here Ideally I'd create the pointer at struct definition time via a declarator. [CODE=C]// drawscr.cpp #include <iostream> …

Member Avatar for Duoas
0
283
Member Avatar for guitarrick

Hello again everyone. This one is a project to help with understanding another project (aren't they all?)... At any rate, this was running up through main where I was attempting to call and get my grade computation function (which you'll see a bunch of stuff commented out). I fooled around …

Member Avatar for guitarrick
0
112
Member Avatar for finalheavenx

help me make this shorter.. i think this is too long.. i'm a newbie student.. #include <iostream.h> #include <conio.h> int main() { int x, n=0; clrscr(); for(x=1;x<=5;x++) cout << " " << x; if(++n==5) { cout << " " << endl; } n=0; for(x=2;x<=5;x++) cout << " " << x; …

Member Avatar for WaltP
0
117
Member Avatar for kittycat07us

Hi. I was wondering if someone could help me with this program.. the purpose of this program is to play tic tac toe, and I'm having difficulty getting it to compile. I have gone through it several times. I would most appericate it if anyone could look at it and …

Member Avatar for Ancient Dragon
0
87
Member Avatar for kv79

Hi to all, just a small question? This is typed in the book. hInstance is used for things like loading resources and any other task which is performed on a per-module basis. What is pre-module basis. Google won't help.

Member Avatar for kv79
0
89
Member Avatar for lacy1104

I am working on a project in which i have to use Classes and do multiple things with different sorts of data. The basic question i have though is this: what am i doing wrong here in terms of this class declaration etc...i get ton of errors and cant seem …

Member Avatar for Ancient Dragon
0
217
Member Avatar for Underdog67

I'm having a lot of difficulty trying to figure out how to label headings in a 2D array using enum type. Here is the basic for-loops to read in and out the values of an array. (This is a 5x5 array). [CODE] #include <iostream> #include <fstream> #include <iomanip> #include <cstring> …

Member Avatar for Duoas
0
2K
Member Avatar for ferrari77

#include<string> #include<iostream> #include<fstream> using namespace std; class fileHandleString { private: ifstream infile; ofstream outfile; public: fileHandleString() { infile.open("input.txt", ios::in); outfile.open("output.txt", ios::in); } ~fileHandleString() { infile.close(); } string getFromFile() { string str; getline (outfile, str); return (str); } }; The above code is what I am using but I keep getting …

Member Avatar for Duoas
0
494
Member Avatar for ENG ISE student

I am getting an error i dont recognize and dont know what to do to fix it and input would be great. The error is: [CODE]prog4.cpp:23: error: no matching function for call to 'std::basic_istream<char, std::char_traits<char> >::get(char [500])'[/CODE] [CODE] #include <iostream> #include <ctype.h> #include <cstring> using namespace std; void encrypt(char ch, …

Member Avatar for Ancient Dragon
0
98
Member Avatar for raj1

I am using a for loop to calculate the distance between the vertices of a polygon using for (i=0; i<N, i++) { j= (i-1) result = sqrt (sqr(X-X[j])+sqr(y-y[j])); } return result; This work fine however it doesn't and I cant calculate the distance between the last and first vertice e.g …

Member Avatar for raj1
0
108

The End.