Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Clipboard 101 question re: copying and pasting in place

Status
Not open for further replies.

SBendBuckeye

Programmer
May 22, 2002
2,166
US
I have some special case formatting that I want to do that could be done (I think) in the following steps:

1. Select block of text by dragging mouse to define it
2. Copy to clipboard
3. Read clipboard and do special case formatting
4. Copy back to clipboard
5. Paste back over original block of text in place

I know these are entry level questions but please bear with me. As an example, let's say I selected lines 3 to 5 to form a block of text and want to upcase every other letter.

Using the above scenario, when I do the last replace will it overright my original selection of lines 3 to 5 or will my code need to reselect it since there were intervening steps taken? If I need to reselect it, how do I do that?

Ideally, I would like to assign the block of text to a text variable, do the manipulations and then paste it back directly. Is this doable?

Thanks in advance for any help and/or suggestions you can give me and have a great day!




 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top