Thursday, March 7, 2013

Filing With Simple Format

By Unknown   Posted at  1:36 AM   C++ Programming 1 comment

#include<iostream>
#include<fstream>
#include<iomanip>
using namespace std;
int main()
{
    ofstream anyfile;
    anyfile.open("Result.txt", ios::out);
    if(!anyfile) // checking for file creation
    {
        cerr<<"\n File Opening Error"<<endl;
    }
    cout<<"\n \tFile Created Successfully...\n";
    cout<<" if You Want to Keep Prevoius Data in UR Created File, Replace out with\n app in Line#8 of Code\n";
    anyfile<<"\n i m a Muslim boy of Asian Timezz...\n Islam is my Life Style...\n";
    anyfile.close(); //closing command of File...
    system("pause");
}

About the Author

Nulla sagittis convallis arcu. Sed sed nunc. Curabitur consequat. Quisque metus enim, venenatis fermentum, mollis in, porta et, nibh. Duis vulputate elit in elit. Mauris dictum libero id justo.
View all posts by: BT9

1 comment:

Back to top ↑
Connect with Us

    What's Trending in Videoism

    Total Pageviews

    Copy of any Post is Not Allowed. All Rights Reserved with Matee ur Rehman (Author). Powered by Blogger.

    Advertisements

    Follow us on FaceBook

What they says

© 2013 GC Study Timez. WP Daily Quranand Hadith Converted by Matee Gojra
Blogger templates. Proudly Powered by Blogger.