c# - how to set the cursor position in a non textbox component -


I am working with a component named SpinAid whose text is property, how do I set the cursor position in this component?

Unless this select-list property, or similar

Text property is a string, which does not have any connection with the cursor in the editor.

If it selects property, you can usually get it and get the cursor index within control. For most controls, which give it a int value, for example, to set the cursor at the beginning of the control:

  control. SelectionStart = 0;  

To set the cursor to the end of the control:

  control. Selection-start = Control Lesson Lang -1;  

However, this will only work when is the property of the control you are using and it allows it to be set. You have not specified where the control comes from, unless you give us more information, there is nothing that we can do to help.


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -