> On 3 Mar 98 at 13:17, Jayoung Wu wrote:
>
>
> > It does not work either.
>
> Did you mean the ROOT macro or your own stand-alone ROOT class
> library based code?
> Valery
>
Yes, I mean my own stand-alone ROOT class ibrary based code.
The following is my code:
======================================================================
printf("Do you want to see tracking plot?(y/n)\n");
scanf("%s",&ans);
if (ans=='y') {
printf("YES!\n");
// Create histograms
TH1F *layer1 = new TH1F("layer1","layer#1 profile",20,-25.,25.);
// Fill histograms
for(i=0; i<20; i++) layer1->Fill(2.5*(j-9)-1.25,yed[1][j]);
// Create a new canvas
TCanvas *c1 = new TCanvas("c1","Tracking of Incident Particle",
200,10,700,500);
c1->SetFillColor(42);
c1->GetFrame()->SetFillColor(21);
c1->GetFrame()->SetBorderSize(6);
c1->GetFrame()->SetBorderMode(-1);
layer1->Draw("cp");
c1->Modified();
c1->Update();
=======================================================================
Up to line 4 it works fine. It prints out YES! and exit from program.
I will try the ROOT macro version.
-------
THanks,
Jayoung Wu