How to renew my data during Geant4 simulation

Hi, everyone!
I’m a beginner of root and geant4, trying to use root to analysis my simulation results. I was using TBrowser b command to read the .root file created by Geant4 code. But every time I got a new result I have to re-open the browser window to read my newest result. Dose anyone know a more convenient way to do this?

ROOT Version: 6.20
Platform: Mac 10.15.4

I appreciate for any advice! Thanks in advance.

Lan

What do you mean by “new result” ? is it a new version of the same ROOT file or a new ROOT file ?

Hi, couet!
It’s a new version of the same root file.

@couet Unfortunately, ROOT does not offer any “reopen” file option.

You need to “Close” your file and then “Open” is again (this can be done with the “right mouse button” in the TBrowser when clicking on the file name).

You can also easily do it “manually” there. In the “Command (local):” field execute:
{const char *s = "/your/file.root";delete gROOT->GetFile(s);TFile::Open(s);}
Then you will need to double-click the “ROOT Files” item there TWO times in order to “refresh” its contents (the first time it will “close” and then it will again “open” the doubly linked list of opened files).

Dear Wile_E_Coyote,

Thank you very much!
Okay, I thought there is a “shortcut”. But it looks like I have to do it this way.