Full Version: Cut-N-Paste Text

From: Carl (CSEWELL) [#1]
 9 Aug 2006
To: ALL

All;

A new macro based on a concept by LogoJohn. Basically, it facilitates pasting text into CorelDraw text objects. ImportText works for one item of changing data (ie a name). Cut-n-Paste can also work for multiple lines of data provided they are ordered correctly and each item is on a separate line on the clipboard. For example, if you have a text file with a persons name and title on subsequent lines, the lines can be pasted, in order, into CorelDraw text objects. You can use CopyXY to create a number of copies and use Cut-N-Paste to fill those copies with names/titles/phone numbers, etc.

Select the text objects before starting the macro. If you have multiple columns AND multiple data items (not just names), only work with one column at a time. They must be in bottom-up order in the object manager to match the displayed top-down order. If they aren't, there's a command box in the macro that will do this for you: Order Text Objects. When that button is clicked, the selected objects will be ordered and the macro will exit. You'll have to reselect the text objects (sorry, a strange anomaly in CorelDraw and I couldn't find an easy work-around) and run the macro again to cut-n-paste text. You can have the items already on the clipboard before running the macro or add them after the macro is started. The REFRESH button will recount the clipboard items to verify that you have a one-to-one match between the text objects and lines on the clipboard. It shouldn't matter if it isn't one-to-one, but the results may not be what you expected.

This macro can also be used for one data object (ie a name) and items on the clipboard. The items don't have to be sorted and you can work with multiple columns. Be careful when copying text from e-mails! If the e-mail is in HTML format, it may not work properly because the lines will not be terminated with CR/LF. Convert the e-mail to plain text format and then re-copy the list to the clipboard.

Please let me know if you find this macro useful and/or if you have troubles with it.

Back to thread list | Login

© 2024 Project Beehive Forum