views:

24

answers:

1

Hi,

I have a cocoa application, that on pressing a certain key gets selected text from the frontmost application and processes it. Now I'd like to replace the selection that it took with a processed text. How do I do it?

TIA

+1  A: 

Look into the services system...

http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/SysServices/Articles/using.html#//apple_ref/doc/uid/20000854-CEGDDHJJ

Jakob Dam Jensen
thanks, solved it with apple script
Nava Carmon