Hi,
I want to set the clipboard to text data as specific type/class. This is for sharing data between apps. And works like this:
set theClass to «class TEST» --the class name is irrelavant
set theClip to "This is a test string"
set the clipboard to {class:theClass, data:(theClip)}
Now the clipboard contains this data:
But it shut be:
without any dots and the prefix: dle2…TEST…>…rdatutxt…*.
You can analyze the clipboard with the app “Clipboard Viewer.app”. You find it on your HD /Developer/Applications/Utilities.
One thing may be the character encoding - the clipboard represents the data in utf-16 (2 Bits) and not in ascii (1 Bit)? Is this the reason for the dots?
Is there any possibility to manipulate the clipboard in my way? Or is shell command “pbcopy” a solution?
Regards,
finder
AppleScript: 2.2.1
Browser: Safari 525.27.1
Operating System: Mac OS X (10.5)