#include "stdafx.h"
#include "gwin.h"
#include <iostream>
#include <fstream>
using namespace std;
int main() // starting point of program - the main function is always called this name
{
// Variable declarations
double account [3][8];
ifstream myfile("finances.txt");
int counter = 0;
if (!myfile)
{
Gwin.writeText("Oh dear, one of your files could not be opened");
Keyboard.getch();
exit(1); //an error code to denote what has gone wrong
}
while (counter<24)
{
myfile >> account[counter];
counter++;
}
myfile.close();
Gwin.writeDouble(100,100,account[1][1]);
// Finally, wait for a key to be pressed
Keyboard.getch();
return 0;
}
the error I get is
error C2679: binary '>>' : no operator found which takes a right-hand operand of type 'double [8]' (or there is no acceptable conversion)
Thanks again for your help.
Warchilo.

New Topic/Question
Reply




MultiQuote








|