Guest Petyas Posted February 7, 2006 Report Posted February 7, 2006 How is it possible to get a caret position (row,collumn or current char position in string) in textbox control. TextBox have a method Select(position, length), but how can i obtain current position? If isn't way in C#, exists some method what i can import from any DLL? I found only method GetCaretPosition from coredll.dll. This method returns x, y position of caret, but this method i cannot use, because every char has a different width. This i need for select, cut, copy and paste. Any idea? Thanks
Guest GregBlast Posted March 25, 2009 Report Posted March 25, 2009 It is "TextBox.SelectionStart". You can either get it and set it.
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now