अपनी आईडी द्वारा OS X मेल संदेश तक पहुँचें


1

मैं एक मेल संदेश ('ड्राफ्ट' फ़ोल्डर में स्थित) को अपनी संदेश आईडी द्वारा प्राप्त करने का असफल (असफल) प्रयास कर रहा हूं।

निम्नलिखित कोड:

set theContent to getContent(123456)

on getContent(theID)

  tell application "Mail"       
    try
      return ((content of message whose message id is theID) as rich text)
    on error errText number errNum
      display dialog "Error: " & errNum & return & errText
    end try

  end tell

end getContent

एक त्रुटि उत्पन्न करता है जो पढ़ता है: Error -1723. Can't get the content of message whose message id = 123456. Access not allowed.

मैं क्या खो रहा हूँ?


यह AppleScript नहीं है, लेकिन यदि आप केवल संदेश देखना चाहते हैं, तो आप URL खोलकर इसे खींच सकते हैं message://<YOUR-MESSAGE-ID@HERE>। के जरिए orgmode.org/worg/org-contrib/org-mac-message.html
Jeremy W. Sherman

जवाबों:


1

प्रयत्न:

tell application "Mail" to get content of (first message of drafts mailbox whose id = 123456)
हमारी साइट का प्रयोग करके, आप स्वीकार करते हैं कि आपने हमारी Cookie Policy और निजता नीति को पढ़ और समझा लिया है।
Licensed under cc by-sa 3.0 with attribution required.