This is an old revision of the document!
When you write a ROOT-file in mehtod with:
file->Write()
and the file exists, but is empty, check the right order of the files: Do
TFile* inputFile = TFile::Open("myInputFile.root"); TFile* outputFile = new TFile("myOutputFile.root", "RECREATE"); // your code outputFile->Write();
but don't
TFile* outputFile = new TFile("myOutputFile.root", "RECREATE"); TFile* inputFile = TFile::Open("myInputFile.root"); // your code outputFile->Write();
as your file will be empty.