NumericUpDown text selection

  • Thread starter Thread starter Pavel Volin
  • Start date Start date
P

Pavel Volin

Hi,

I use SelectionStart property for set the starting point of text selected in
the text box. But unfortunately, NumericUpDown control not have this
property.
Would there be any way to set a point of text selection in the NumericUpDown
control?

Best regards
Pavel
 
The only way I can think of is to use PInvoke:

[pseudo code]

NumericUpDown ud1;

ud1.Capture = true;
IntPtr pCtl = GetCapture();
IntPtr pBuddy = SendMessage(pCtl, UDM_GETBUDDY, 0, 0);
SendMessage(EM_SETSEL, pBuddy, ... )
 
Back
Top