Hi guys i want create a program that can write to a pdf file and here is the code i used.
when i run the program, it compiles well, and runs but the pdf file that is created is not readable/corrupt. i am just wondering whether there is some library that am supposed to use ......... thanx
#include<iostream>
#include<fstream>
using namespace std;
int main(){
ofstream myFile;
myFile.open("sample.pdf");
myFile << "This is a sample for writing to a pdf file";
myFile.close();
return 0;
}