Fedora Linux Support Community & Resources Center
Old 24th January 2009, 02:33 PM
gowrishankar Offline
Registered User
Join Date: Jan 2009
Posts: 17
error: expected ‘;’ before ‘(’ token in c++

iam using sulphur....i was trying to create a file in c++ using the statement
fstream &myFile("file.txt");

and i got the following error

error: expected ‘;’ before ‘(’ token

help me to get through this problem..

thanks in advance
Reply With Quote
Old 24th January 2009, 02:36 PM
bee Offline
Join Date: Jun 2008
Posts: 1,312
Try with this one:
fstream myFile("file.txt", ios::in | ios::out);
without the "&" and with open-mode flags.

Reply With Quote

error, expected, token

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
passwd: Authentication token manipulation error phildog Using Fedora 10 5th February 2017 01:33 AM
Implementing Token ring Beagleboy Servers & Networking 2 23rd March 2009 01:19 PM
winecfg error fscanf returns 1, expected 2 sdowney717 Using Fedora 7 4th July 2007 02:33 PM
"expected specifier-qualifier-list" ERROR while adding a new system call ahm_irf Programming & Packaging 0 30th April 2007 04:49 AM
Installation Error: MD5 digest: BAD Expected [INTEL FORTRAN COMPILER] aftab Installation, Upgrades and Live Media 5 28th February 2006 04:08 PM

Current GMT-time: 13:33 (Thursday, 17-08-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletinฎ Copyright ฉ2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat