problem in drwaing lines, or string on gamecanvas after using layer manager

Hi to all,
Hope you all will be fine. Actually i am making a cricket game. The problem is that i want to display ball and runs in a rectangle staring at (0.0) or you can say i want to draw something on the screen right now. The problem is that i used layer manager and now when i use code like this

Java Code:

g.drawString(..);
g.drawline(..)

it appears and then suddenly disappear from the screen. I want to ask what i am doing wrong and how can i do what i want. Here is my code