How to Clear tabpage text created by graphic object
-
I have created a graphic object on a tabpage as follows: Graphics g = null; g = tabPage1.CreateGraphics(); g.DrawString(str_1, fnt, brsh, x, y); g.Dispose(); str_1 has been displayed successfully. But how do I clear the existing text and display another text on the tabpage (tabpage.Controls.Clear() didn't work)? At the moment, the problem is that the new text is displayed on top of the existing ones.
-
I have created a graphic object on a tabpage as follows: Graphics g = null; g = tabPage1.CreateGraphics(); g.DrawString(str_1, fnt, brsh, x, y); g.Dispose(); str_1 has been displayed successfully. But how do I clear the existing text and display another text on the tabpage (tabpage.Controls.Clear() didn't work)? At the moment, the problem is that the new text is displayed on top of the existing ones.