Output to clipboard, and pasting into Excel - encoding issue

Get help with installation and running here.

Moderators: DataMystic Support, Moderators, DataMystic Support, Moderators, DataMystic Support, Moderators

Post Reply
AnthonyFitz
Posts: 11
Joined: Mon Aug 25, 2008 9:16 pm
Location: Dublin and Manila
Contact:

Output to clipboard, and pasting into Excel - encoding issue

Post by AnthonyFitz »

Hi Simon,

I'm creating a tool in VB that takes in user input and runs a textpipepro filter in command line mode which outputs to the clipboard. Then the tool silently opens up excel and pastes this data into a specific column.

Everything is working great except that its pasting corrupted characters for non english characters. They look like multibyte unicode characters that are not being converted correctly on the clipboard.

The filter works fine if outputed to a text file so I think it is not a problem with the filter.

Is there something I need to do to handle the clipboard contents differently to make it paste correctly?

Thanks.
Anthony.
http://www.TheLocalizer.com/
High Quality, Low Cost, Localization Engineering, Testing, Audio & Video Services
User avatar
DataMystic Support
Site Admin
Posts: 2227
Joined: Mon Jun 30, 2003 12:32 pm
Location: Melbourne, Australia
Contact:

Re: Output to clipboard, and pasting into Excel - encoding issue

Post by DataMystic Support »

Hi Anthony,

Currently, TextPipe will only grab ANSI text from the clipboard. If you have Unicode data on the clipboard then it will be converted silently to ANSI, and non-english characters will appear as gibberish.

We've just made a change to fix this. It's in the 8.5 beta - http://www.datamystic.com/textpipeprobeta.exe

You will need to add filters at the top and bottom of your filter list to convert incoming text from Unicode UTF16-LE to UTF-8, and UTF-8 to UTF16-LE. e.g.

|--Input from clipboard
| [X] Unicode input
|
|--Convert from UTF-16LE to UTF-8
|
|--Comment...
| handle normal string processing here
|
|--Convert from UTF-8 to UTF-16LE
|
+--Output to clipboard
[X] Unicode output
Attachments
test unicode clipboard.zip
(607 Bytes) Downloaded 395 times
AnthonyFitz
Posts: 11
Joined: Mon Aug 25, 2008 9:16 pm
Location: Dublin and Manila
Contact:

Re: Output to clipboard, and pasting into Excel - encoding issue

Post by AnthonyFitz »

Perfect, thanks Simon!

Amazing, super fast support. Top Class!

Anthony.
http://www.TheLocalizer.com/
High Quality, Low Cost, Localization Engineering, Testing, Audio & Video Services
Post Reply