Hi,
I need to access to a subbranch of a TTree, but unfortunatly I can’t figure out how to do this.
I have tried many things, by using SetBranchStatus, SetBranchAddress, GetBranch, FindBranch and SetAddress, but I must not have find the right order… They all crash with a segmentation violation because the program doesn’t find the subbranch. However, it exists, as showing by the result of GetListOfBranches :
[code]root [3] tree->GetListOfBranches()->Print()
*Br 310 :misc : QRTmicro/i:micro/i:macro/i:helicity/S:gms_mask/S: *
-
| evt_type/S *
*Entries : 691849 : Total Size= 12496704 bytes File Size = 5527311 *
*Baskets : 390 : Basket Size= 32000 bytes Compression= 2.26 *
…[/code]
I also tried the Tree4r.C code given here (first reply), but I’m not able to use it correctly :
root [10] bpx->SetAddress(px);
Error: illegal pointer to class object bpx 0x0 121 (tmpfile):1:
*** Interpreter error recovered ***
All suggestions are welcome…
Thanks.