My Professional Profile

I am Johnson Augustine Sr.Software Engineer and System Architect. I have 10 Yrs of hands on expertise in ASP.net MVC 5 , Angular 5 , C# MVC Razor, WPF MVVM , Android , IOS Swift 3 , IOS11 MSSQL,MySQL Database,,PHP,C/C++/Visual C++/G++/QT++,Com,DirectX,Open CV,EMGU CV , embedded System Development , [Raspberry PI]. ,html,Javascript,Jquery,Ajax.CSS , Networking ,Cyber security, Ethical Hacking You can see my professional profile at http://linkedin.com/in/johnsontaugustine Email : johnsonaugustine@live.com

Thursday, 25 April 2013

Opening File and Reading Text file line by line in c++ streams and storing to the string array


Opening File and Reading Text file line by line in c++ streams and storing to the string array
int m_LineCount=0;
std::string m_Line[7];
std::ifstream m_Settings ("Settings.txt");
if (m_Settings.is_open())
{
while (m_Settings.good()) {
std::getline(m_Settings,m_Line[m_LineCount]);
std::cout<<m_Line[m_LineCount]<<"\n"<<"LineCount"<<m_LineCount;
m_LineCount++;
}
m_Settings.close(); // Closing the openned Txt settins file

No comments:

Post a Comment

Note: only a member of this blog may post a comment.