String In Csharp

 

Saturday, May 30, 2009

Numeric textbox (accepts only numbers and shows a warning popup when invalid)

// Numeric textbox (accepts only numbers and shows a
// warning popup when invalid)

public class NumericTextbox : TextBox
{
protected override CreateParams CreateParams {
get
{
CreateParams cp = base.CreateParams;
cp.Style |= 0x2000; // ES_NUMBER
return cp;
}
}
}

No comments:

Post a Comment

All Menu