Click here to Skip to main content
15,897,704 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralPicture Problem Pin
Kehllendros21-Nov-04 15:27
Kehllendros21-Nov-04 15:27 
GeneralRe: Picture Problem Pin
BaldwinMartin23-Nov-04 10:18
BaldwinMartin23-Nov-04 10:18 
GeneralFind your apps path Pin
Don1221-Nov-04 15:19
Don1221-Nov-04 15:19 
GeneralRe: Find your apps path Pin
ThatsAlok21-Nov-04 17:21
ThatsAlok21-Nov-04 17:21 
GeneralRe: Find your apps path Pin
BaldwinMartin23-Nov-04 10:24
BaldwinMartin23-Nov-04 10:24 
GeneralIterations with GUI's in Windows Pin
vsapuy21-Nov-04 15:00
vsapuy21-Nov-04 15:00 
GeneralIrda Com port without MFC Pin
jhop@earthling.net21-Nov-04 12:04
jhop@earthling.net21-Nov-04 12:04 
GeneralReading data from a file Pin
Dr Dan21-Nov-04 11:28
Dr Dan21-Nov-04 11:28 
I have a text file which contains a list of sets of four floating point numbers. They are arranged like this, each * representing some number in the file:

* *
* *

* *
* *

.
.
.

and so on, but I don't know in advanced how many sets of four there are. I need to read them into a program using C++/VC++/MFC and I'm wondering if there is a "best" way to do it?

Currently I am using

<br />
while(fscanf(stream, "%lf %lf %lf %lf", a, a + 1, a + 2, a + 3) == 4)<br />
{...}<br />


where a is an array

double a[4];.

I'm guessing this isn't a particularly good way to do it...
GeneralRe: Reading data from a file Pin
Christian Graus21-Nov-04 14:28
protectorChristian Graus21-Nov-04 14:28 
GeneralRe: Reading data from a file Pin
BaldwinMartin23-Nov-04 10:26
BaldwinMartin23-Nov-04 10:26 
GeneralStatic member funciton call non-static function Pin
Zero_G21-Nov-04 10:32
Zero_G21-Nov-04 10:32 
GeneralRe: Static member funciton call non-static function Pin
bmzhao21-Nov-04 13:57
bmzhao21-Nov-04 13:57 
GeneralRe: Static member funciton call non-static function Pin
Christian Graus21-Nov-04 14:29
protectorChristian Graus21-Nov-04 14:29 
GeneralRe: Static member funciton call non-static function Pin
nguyenvhn21-Nov-04 22:27
nguyenvhn21-Nov-04 22:27 
GeneralRe: Static member funciton call non-static function Pin
Christian Graus21-Nov-04 22:59
protectorChristian Graus21-Nov-04 22:59 
GeneralRe: Static member funciton call non-static function Pin
nguyenvhn21-Nov-04 23:36
nguyenvhn21-Nov-04 23:36 
GeneralRe: Static member funciton call non-static function Pin
Christian Graus21-Nov-04 23:43
protectorChristian Graus21-Nov-04 23:43 
GeneralRe: Static member funciton call non-static function Pin
nguyenvhn22-Nov-04 0:25
nguyenvhn22-Nov-04 0:25 
GeneralRe: Static member funciton call non-static function Pin
Steve S22-Nov-04 0:32
Steve S22-Nov-04 0:32 
GeneralTutorial for Visual C++ .NET 2003 Pin
Rylogy21-Nov-04 9:37
Rylogy21-Nov-04 9:37 
QuestionSTL fstream brakedown in VS .NET? Pin
Robert Bielik21-Nov-04 9:08
Robert Bielik21-Nov-04 9:08 
AnswerRe: STL fstream brakedown in VS .NET? Pin
Aamir Butt21-Nov-04 20:34
Aamir Butt21-Nov-04 20:34 
GeneralRe: STL fstream brakedown in VS .NET? Pin
Robert Bielik21-Nov-04 20:42
Robert Bielik21-Nov-04 20:42 
GeneralBits; Pin
Bo Hunter21-Nov-04 8:38
Bo Hunter21-Nov-04 8:38 
GeneralRe: Bits; Pin
Neville Franks21-Nov-04 10:13
Neville Franks21-Nov-04 10:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.