PDA

Click to See Complete Forum and Search --> : Detecting letters in a text box???


rino_2
Nov 10th, 1999, 12:49 AM
Hi,

I would like to know how to detect what letter is 5 spaces across in a label. For example, in a label called lblLetters with a caption of ‘Visual Basic’ the result would be ‘l’. It would find ‘L’ because ‘L’ is five spaces to the right from the start of the word.

Thanks

Serge
Nov 10th, 1999, 12:56 AM
You can use Mid function.


Dim strText As String

strText = "This is my test"

MsgBox Mid(strText, 4, 1)


Second parameter for the Mid function is the Start position (in this case it's 4) and the second parameter is the length (in this case 1 (1 character)

Regards,

------------------

Serge

Software Developer
Serge_Dymkov@vertexinc.com
Access8484@aol.com
ICQ#: 51055819 (http://www.icq.com/51055819)