Applescript for Mail

Discussion in 'Mac Programming' started by RusselM, Oct 10, 2016.

  1. RusselM, Oct 10, 2016
    Last edited by a moderator: Oct 11, 2016

    RusselM macrumors newbie

    Joined:
    Oct 10, 2016
    #1
    "I'd like to run an Applescript to open "System Preferences > Internet Accounts" then unselect "Mail" from each of my accounts.



    How can this be done with Applescript? BTW, the only code I've figured out so far is the following:


    Code:
    tell application "System Preferences"
    
     activate
    
     set the current pane to pane id "com.apple.preferences.internetaccounts"
    
    end tell
    

    (BTW, the reason is that when my Apple Mail crashes, which unfortunately is fairly often, this is the only way to get it to open again)"
     
  2. superscape macrumors 6502a

    superscape

    Joined:
    Feb 12, 2008
    Location:
    East Riding of Yorkshire, UK
    #2
    Mmmm... not sure.

    However, I'd be more inclined to spend the time trying to figure out why Mail keeps crashing for you. What have you tried to solve that so far?
     

Share This Page