hi all,

i want to fill the margin area between the tabcontrol and tabpage with color.plz do help me.

thank u.

raghu

Recommended Answers

All 6 Replies

What exactly do you mean by margin area ?

The margin around the visible TabPage

danny r u there plz reply

The only possibility I see for the moment is that you derive a class from the TabControl class and override the OnPaint method.

i have done what u have said. now how to code in onpaint method.

I assume you have something like this :

class MyTabCTRL : TabControl
    {
     //some things here
        protected override void OnPaint(PaintEventArgs pe)
        {
            base.OnPaint(pe); //first let the base class do his thing
            Graphics G = pe.Graphics; //you need a Graphics object to draw in
            //now start drawing what you want...
        }
    //some other things here
}

If this is not good, please show us some of your code.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.