defining action on the TControlBar

Luca Sfarzo (l.sfarzo@agora.smt.it.cern.ch)
Thu, 04 Sep 1997 12:56:03 +0200


Hello,

I am using Root' TControlBar to make an interface.
I am writing a stand alone prog.
All seem to work when but when the program ties to run the function
attached to the button I press I get a strange behaviour.

part of the code is:

....
1) TControlBar *MainBar = new TControlBar("vertical");

2) MainBar->AddButton("Content of the dir","shoContent(*nameFile, f)",
"Show content");

3) MainBar->AddButton("Change directory", "changeDir()", "Change the
current Directory");

4) MainBar->AddButton("Display the Histo", "shoHistos()", "Display the
Histos");

5) MainBar->AddButton("Quit session", "exit();", "Close the
controlBar");

6) MainBar->Show();

7) theApp->Run();
8) delete theApp;
9) ...

when I run it and press the first button it says:
Error: Incorrect referencing of $nameFile FILE:/var/tmp/aaaa10082
LINE:1
Error: Incorrect referencing of $f FILE:/var/tmp/aaaa10082 LINE:1
*** Interpreter error recovered ***

but the two vars nameFile and f are well defined (I print it).

If I press the "Quit session" button i get such error:
(int)0
*** Interpreter error recovered ***
...

Can u help me?

Many thanks, Luca Sfarzo