Stephane,
Yeah, I agree with you on the VB. <g> I just copied Eric's code and took out the unncessary stuff (and didn't notice that it needed that extra line that you added). If I had posted it myself, I would have posted C# code. =)
~~Bonnie
>Thank-you to both of you, it works, but i just added an important line of code:
>
>
>public class MyTextBox : System.Windows.Forms.TextBox
>{
>
> protected override void OnTextChanged(System.EventArgs e)
> {
> if (this.Text.Length == 0)
> {
> if (this.DesignMode)
> this.Text = this.Name;
> else
> base.OnTextChanged(e);
>
> }
> }
>}
>
>
>Sorry, i can't write in VB. I couldn't teach myself to write "Me".something ;)
>
>Stephane