Scriptable application can not return record data
Scriptable application can not return record data
- Subject: Scriptable application can not return record data
- From: Takaaki Naganoya <email@hidden>
- Date: Thu, 29 Jan 2015 17:10:38 +0900
G’day scripters
I made a ASOC based small application with Xcode. This application is fully written in ASOC.
I want to add scriptable function with it (almost be discouraged :-) ).
My app can return string, number & file path to AppleScript.
But could not return *record* and *list*.
When I return record data, logging message says…
Trial 1:return record from ASOC app—> Failed
<log message>
...could not be converted to an Apple event descriptor of type 'record'. This instance of the class '__NSDictionaryM' doesn't respond to -scriptingRecordDescriptor messages.
</log message>
Trial 2: cover record to NSDictionary and return it —> Failed
<log message>
...could not be converted to an Apple event descriptor of type 'record'. This instance of the class '__NSDictionaryI' doesn't respond to -scriptingRecordDescriptor messages.
</log message>
Trial 3: use Apple’s private method NSAEDescriptorTranslator's sharedAEDescriptorTranslator() —> Failed
set retVal to current application's NSAEDescriptorTranslator's sharedAEDescriptorTranslator()'s descriptorByTranslatingObject:aRec ofType:(missing value) inSuite:(missing value)
<log message>
<NSAppleEventDescriptor: { 'usrf':[ 'utxt'("aRes"), 'utxt'("This is Test") ] }>
...could not be converted to an Apple event descriptor of type 'record'. This instance of the class 'NSAppleEventDescriptor' doesn't respond to -scriptingRecordDescriptor messages.
</log message>
Is there any advice?
--
Takaaki Naganoya
email@hidden
http://piyocast.com/as/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
applescriptobjc-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden