Problem in the code

I have histrograms and I want to write in the histogram the “CMS Internal”. The following piece of code I used and got this errors. Here it is:


TLatex = new TLatex(1,1,"#splitline{#bf{#it{CMS}} Work In Progress}{#sqrt{s} = 13 TeV, 36.5 fb^{-1}}");
TLatex->SetTextFont(42);
TLatex->Draw();


The errors are:
/storage/local/home/atlas/msohail/trigger_analysis/macro/pt.C:37:8: error: expected unqualified-id
TLatex = new TLatex(1,1,"#splitline{#bf{#it{CMS}} Work In Progress}{#sqrt{s} = 13 TeV, 36.5 fb^{-1}}");
^
/storage/local/home/analysis/macro/pt.C:38:7: error: cannot use arrow operator on a type
TLatex->SetTextFont(42);
^
/storage/local/home/analysis/macro/pt.C:39:7: error: cannot use arrow operator on a type
TLatex->Draw();

TLatex *t = new TLatex(1,1,"#splitline{#bf{#it{CMS}} Work In Progress}{#sqrt{s} = 13 TeV, 36.5 fb^{-1}}");
t->SetTextFont(42);
t->Draw();

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.