slt,
j'ai qqs "erreurs" à la compilation ! c à s'arracher les cheveux, pouvez vous m'aider svp :
#include <iostream.h>
#include <fstream.h>
#include <string>
using namespace std;
.........
string fichierIn, fichierOut, Rep, ficDiag, ficDiag_fsm;
cout << "\n Entrer le nom du fichier \".d\" : ";
//cin >> ficDiag; // ça passe pas !!!
getline(cin, ficDiag); // ça passe pas aussi
fichierIn = Rep + ficDiag + ".d";
ifstream ficIn1( fichierIn.c_str() ); // ça passe pas
if ( !ficIn1 )
{
cout << "\n erreur : le fichier \"" << fichierIn << "\" n'existe pas !!!\n\n"; // ça passe pas
exit(0);
}
par exp pour le getline il me sort :
error C2784 : 'class std::basic_istream<_E,_Tr> &__cdecl std::getline(class std::basic_istream<_E,_Tr> &,class std::basic_string<_E,_Tr,_A> &,const _E)' : could not deduce template argument for 'class std::basic_istream<_E,_Tr> &' from 'class istream_withassign'
et 3 autres erreurs du même style pour getline !
pour le ifstream il me sort :
error C2872: 'ifstream' : ambiguous symbol
pour ce cout il me sort :
error C2679: binary '<<' : no operator defined which takes a right-hand operand of type 'class std::basic_string<char,struct std::char_traits<char>,class std::allocator<c
et après tt les getlignes du style getline(ficIn1,strLigne,'\n') ça marche pas aussi ?!!!!