Usage of TTree / old ROOT files in v2.23_07

From: Stephan Heising (stephan.heising@cern.ch)
Date: Wed Nov 03 1999 - 11:16:01 MET


Hello 
I installed the new version of ROOT v2.23_07 and later v2.23_08 as 
well. I tried to 
used old macros running under v2.22_10. Now when reading an event from 
the ROOT-file
I get error messages:

SysError in <TFile::ReadBuffer>: error reading from file 
mobilfd40s.root (Invali
d argument)

The code is:

   TFile hfile("mobilfd80s.root","READ");
   
   TTree *tree = (TTree*) hfile.Get ("T");
   TBranch *branch = tree->GetBranch ("Davinci");
   TBranch *brt = tree->GetBranch ("Temp");
   TBranch *brb = tree->GetBranch ("Bias");
   branch->SetAddress (&dav);
   brt->SetAddress (&temp);   
   brb->SetAddress (&bias);   
   
   Int_t nevent = tree->GetEntries ();
   printf ("Entries: %d\r\n", nevent);
   ...
   for (Int_t i=0; i<nevent; i++)
   {
>>
      nb += tree->GetEvent (i);
>>   this line produces the error.
      .
      .
      .
   }

It is a modified example of the tutorials. 
What happened???

Cheers Stephan Heising



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:43:42 MET