TClonesArray typecasting

From: George Locke <>
Date: Tue, 14 Nov 2006 13:16:45 -0500

Hey all,

This is a simple question. i'm using the latest root (5.13.04) on windows 2000, compiling with visual C++ 2005 (aka msvc 8).

i filled a TClonesArray with TH1F's, and now i want to fill the histograms.

this code returns the error "'Fill' : is not a member of 'TObject'" (TH1F *) bigArr[chan]->Fill(j, value);

what should i write instead?

for context:
i declared the TClones array with this line: TClonesArray bigArr("TH1F", 8);

and i filled it with this line:
new(bigArr[chan]) TH1F(name,title,HIST_SIZE,0,HIST_SIZE);

Thanks for answering such a simple question, George Received on Tue Nov 14 2006 - 19:16:52 MET

This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:32:02 MET