0

I've googled & searched the site for this with no luck, and you guys were such great help last time. I was hoping someone might have an idea of how to change the current users iMessage icon through Applescript? I have looked through the Messages suite under the applescript library and found that there under the class 'application' there is a property 'image'. The description of which is "My image as it appears in all services". It does not appear to be read only.

I am trying to change that property, but in my limited knowledge of Applescript it does not appear to be working. Here's what I've got:

tell application "Messages"
    set image to NewImage
end tell

NewImage in this case is a POSIX file path (which I'm not sure is right either) ;\

(OSX Yosemite by the way) Thanks :]

  • You are not describing your issue very well. For what purpose do you want to change the icon? Are you changing it once? On a trigger? On a schedule? – Sam Axe Mar 28 '15 at 08:16
  • I updated the info to give people a better idea :D – EveryCrime Mar 29 '15 at 00:34
  • Run "get image" to see the format (data). I assume it must be set in the same format but to create the data from an image is something else. –  Mar 29 '15 at 00:52
  • Hey thanks for the reply. I added get image and looked in the replies when I ran. I see a big long hex number followed by the word "data" in blue. I assume this means that it wants "data" instead of a "POSIX file" path as I have provided. How wpuld I set the file at that path to be the "data"? – EveryCrime Mar 29 '15 at 01:16
  • Here are discussions about that: http://stackoverflow.com/questions/27597696/how-to-manipulate-data-objects-in-applescript/27611835 and check out the links (also the one in the answer's comment) –  Mar 29 '15 at 04:49
  • Thanks for the link! Good find on this discussion. From what I can tell those code snippets only read or write to data files using a string. I'd still need to decipher the actual hex string though, right? To write into that data file, I'd need to write the information in hex format? Yikes. – EveryCrime Mar 31 '15 at 03:46

0 Answers0