Jump to content
Xisto Corporation
Sign in to follow this  

Vs2008: Error C2679 Help?

Recommended Posts

Hey guys,

I'm trying to open a file, however, I'm running into problems:


#include <iostream>using namespace std;#include <fstream>#include "TDirectory.h"bool Listing::loadFileData(FILE* fp){	fseek(fp, 0, SEEK_SET);	ifstream in(fp);	while (in) {		in >> givenName >> surname >> address >> telephone;	}}

struct Listing {	char fname[16], lname[16], addr[16], phnum[16];public:	bool loadFileData(FILE *fp);	const char* givenName() const;	const char* surname() const;	const char* address() const;	const char* telephone() const;};struct Directory {	FILE *fp;	int records;	struct Listing *listings;public:	bool loadFileData(const char* filename);	void display() const;	void close();};


error C2679: binary '>>' : no operator found which takes a right-hand operand of type 'overloaded-function' (or there is no acceptable conversion)

Many thanks,

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.