我在第60行在我的任务中遇到了标题问题。请任何人尽快帮助我。预计'{'令牌之前的非限定id C++
59 void storeFile();
60 {
61 cout<< "All the data members are stored in file." << endl;
62
63 ofstream outFile;
64 const char *outputFileName = ("record.txt");
65 outFile.open(outputFileName, ios::out);
66
67 if(!outFile)
68 {
69 cout<< "\nUnable to open the file." << outputFileName << endl;
70 }
71
72 else
73 {
74 outFile VUID; endl;
75 outFile campusID; endl;
76 outFile studentName; endl;
77 outFile fatherName; endl;
78 }
79 };
错误:预期 '{' 令牌C++在线路之前不合格-ID 60
删除59行上的最后一个分号 – bobah
这个问题似乎是无关紧要的,因为它是关于打字的。 – 2013-06-26 07:44:32
我不知道如何快速谷歌搜索有关确切的错误没有回复你的问题... – Joum