General C++ Programming - May 2014 (Page 22)

Debug error when taking a string and casting it to a float with a file stream
 
Debug Error Projects\Final Project\GrItem\Debug\GrItem.exe R6010 - abort() has been called I was going over this with a friend and it seems as though...
[2 replies] Last: Line 135 will either create a new file and open it or open and truncat... (by cire)
by Chubby
Array
 
I have to question about an array: How do you stop at 3 and calculate the avg and then keeping moving. Since in a file there are 15 num. each student have...
[5 replies] Last: yes thank you tips (by CodingisFun)
Displaying most profitable day
 
Sorry for posting entire code but would be much easier to help. I am trying write a void function which will tally up the totals for each day and then displa...
[1 reply] : This can get you started! ... Biggest_Profit(Orders_Placed, Menu_List... (by poteto)
Bubble sorting a classed array
 
I'm really struggling with bubble sorting a classed array(an inventory). I understand bubble sorting in theory and implementing it into a static array makes sen...
[6 replies] Last: Good job! (by Duthomhas)
New set of eyes.
 
I apologize for this ahead of time, but have been staring at this for hours trying to find the problem. When I run release_memory and send the job number, it...
[2 replies] Last: Unfortunately, that is what I have been doing all day is drawing it ou... (by tmfletcher)
How to select a file from directory in C++
 
I know how to open a specific files by using ifstream infile("something.txt"); but how do you let the user select an arbitrary file from the working dire...
[12 replies] Last: My assessment was based off how steep of a drop off there would be aft... (by Computergeek01)
by Cobryn
Stupid question but problems with binary search
 
Hey all... I'm feeling stupid but I'm having trouble converting this binary search with an int array to use a string array.. Can anyone help me please? ...
[3 replies] Last: You also have the prototype wrong, it needs to know the value it's loo... (by Lowest0ne)
Help with Date Class assignment
 
So I'm fairly new to coding with classes and even though I understand the basic concept behind classes and how to work with simple examples, I'm still strugglin...
[6 replies] Last: If you wanted to use a setter function rather than assigning the vari... (by Codermik)
How do I associate a string read in from a file to an enum value?
 
Problem The issue I'm having is that I am to read in data from a file and display it in a list. I cannot seem to get my EnumMap to work as intended though....
[no replies]
Memento Pattern, snapshot of abstract object?
 
The code below runs correctly (feel free to compile and run it yourself to see what it does). But when I turn Object abstract by uncommenting the line vi...
[9 replies] Last: Ok, if any of you want to implement successive undo's and redo's of op... (by prestokeys)
WIN32 THREAD string return
 
Hi, How can i create a thread that return a string? static keyword WIN32 fname(function parameters){ .... } what keyword have i to use? I' haven't fin...
[no replies]
'wchar_t *' a 'TCHAR [260]' conversion error
 
Hi :) Someone could explain me why this conversion is not correct? int FileSystemExplore(TCHAR *dir,TCHAR* goalstring){ . . TCHAR current_file ; . . ...
[6 replies] Last: Thanks for the exhaustive response ,it's very useful :) (by Franconet)
How do I randomize answer order with push_back ( please view to better understand my question thanks.
 
Hi, can anyone tell me how to now randomize the answer order within this code ? I only included the relevant piece of code of the task in question. ...
[3 replies] Last: If you could give me more of your code and using [*code][/*code] itd b... (by football52)
need help!
 
I have to create these image for a program and The program should be able to show the user the 5 options and let the user select one of the images. I already ha...
[4 replies] Last: loops works great too. i didn't think of using loops, but good one @Dp... (by helnow)
Reverser Function using Recursion
 
So i have a program it works which takes in a word reverses it prints it out. BUT! the problem is that the program is without recursion. I need help to convert ...
[2 replies] Last: @JLBorges Thank you so much!! (by fbhkhan)
Why happen this loop?
 
Can anyone tell me why the result of the follow program is a loop? #include <iostream> using std::cout; using std::cin; using std::endl; unsigned long...
[9 replies] Last: I understand!! Thank you very much! (by karamaniotis)
by ak16
MAP and Set
 
1. Diff between set and map? and where should use which set/map? 2. Map is implemented by which data structure?
[6 replies] Last: More efficient in what use? The reference documentation describes the... (by keskiverto)
by poteto
Initializing boost asio variables in a state program
 
There's this problem that I took too much time trying to figure out. The problem is that I am trying to initialize this chunk of code without it starting at...
[8 replies] Last: you don't need to move it, just reset: c.reset(new chat_client( io_se... (by coder777)
Deleting records from txt file
 
is this the right codes for deleting a recoed on the text file. void dlte(){ string line, recorddate; cout << "Please Enter the date of record you w...
[1 reply] : This code if (line != recorddate) compares the entire line, to see w... (by Chervil)
Intermediate input/output buffer/s for filebuf objetcs
 
Hi, The documentation of the class filebuf in the reference of cplusplus.com says: Objects of this class may internally maintain an intermediate input ...
[2 replies] Last: This is the relevant code executed in my platform: // First, the b... (by DavidIRE)
May 2014 Pages: 1... 2021222324... 31
  Archived months: [apr2014] [jun2014]

This is an archived page. To post a new message, go to the current page.