Watermark in System.Windows.Forms.TextBox

前端 未结 2 1232
迷失自我
迷失自我 2020-11-27 06:07

What is he best way to implement Watermark functionality for a System.Windows.Forms.TextBox in .Net 2.0 with C#?


Edit:

Using the ready-mad

2条回答
  •  眼角桃花
    2020-11-27 06:38

    It is not as straightforward as one would think. You need to use using the System.Drawing namespace and override the OnPaint event.

    Here are some links of some people that have already done it.

    Link & Link

提交回复
热议问题