How to copy the slected text in a text box

  • Thread starter Thread starter Marco
  • Start date Start date
M

Marco

Hello.

I want to make some changes in the selected text in a text box.

Imagine that I have this text in a text box:
"The Web Server may be down, too busy, or experiencing other problems
preventing it from responding to requests. You may wish to try again at a
later time. "

Imagine that I select some part of text and in the selected area I want to
add the folowing codes: <b> </b>

In the example, imagine that I select "Web Server", I want to press a button
and add the codes to that text in order to get this:

"The <b>Web Server</b> may be down, too busy, or experiencing other problems
preventing it from responding to requests. You may wish to try again at a
later time. "

Please help,
Marco
 
Marco said:
I want to make some changes in the selected text in a text box.

Imagine that I have this text in a text box:
"The Web Server may be down, too busy, or experiencing other problems
preventing it from responding to requests. You may wish to try again at a
later time. "

Imagine that I select some part of text and in the selected area I want to
add the folowing codes: <b> </b>

In the example, imagine that I select "Web Server", I want to press a button
and add the codes to that text in order to get this:

"The <b>Web Server</b> may be down, too busy, or experiencing other problems
preventing it from responding to requests. You may wish to try again at a
later time. "


Imagine that my test scenario is the same as yours ;-)

I did that by using:
Me.Text0.SelText = "<b>" & Me.Text0.SelText & "</b>"
in the text box's Exit event procedure.
 
Back
Top