action in TButton

From: Judith Katzy (katzy@nanalpc.phy.uic.edu)
Date: Wed Apr 29 1998 - 23:17:18 MEST


Dear rooties,

I have a macro  tbut.C that I want to execute as a TButton action, but I 
get error messages. The macro is:

#include <stdio.h>
int tbut(Int_t ilayer) 
{
 printf("ilayer= %d\n",ilayer);
 return 0;
}

The DialogCanvas with button is:

{
TDialogCanvas *dialog = new TDialogCanvas("dialog","",700,780);
TButton *but = new TButton("test",".x tbut.C(0)",.05,.8,.95,.88);
but->Draw();
}

When I click on the test button I get the error message:

Error: file tbut.C(0) can not open

But I can execute the macro on the commandline via
ROOT> .x tbut.C(0)

What's going wrong? I thought I could do it (according to ROOT talk 
July 17, 1997).

thanks for any help
Judith



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