Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8454175
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T11:57:22+00:00 2026-06-10T11:57:22+00:00

I am forced to use Outlook for Mac connected to corporate Exchange at work

  • 0

I am forced to use Outlook for Mac connected to corporate Exchange at work and I have pieced together a small AppleScript to alter subject lines of incoming email messages from our monitoring system. By default they are of an ungodly length and not human readable. I am attempting to fix that.

The script works, but for some strange reason everything is working great when I send test messages myself, however all changes are reverted back when the real messages from the monitoring system come in! When message arrives into my mailbox the subject is exacly how I want it, but within 3-5 seconds it reverts back to the original subject!

I do not know anything about AppleScript and have no idea where to beging troubleshooting something like this.

Would anyone please take a look and tell me if what I am attempting to do is doable?

on replaceText(find, replace, subject)
    set prevTIDs to text item delimiters of AppleScript
    set text item delimiters of AppleScript to find
    set subject to text items of subject

    set text item delimiters of AppleScript to replace
    set subject to "" & subject
    set text item delimiters of AppleScript to prevTIDs

    return subject
end replaceText

tell application "Microsoft Outlook"
    set theMessages to the current messages
end tell

repeat with theMsg in theMessages
    tell application "Microsoft Outlook"
        set mysubject to get the subject of theMsg
        if mysubject contains "[Subscription:Spectrum CTO] SPECTRUM - " then
            set mysubject to my replaceText("[Subscription:Spectrum CTO] SPECTRUM - ", "", mysubject)
            set mysubject to my replaceText("Alarm Title: ", "", mysubject)
            set mysubject to my replaceText("Severity: ", "", mysubject)
            set mysubject to my replaceText("Model Name:", "-", mysubject)
            set subject of theMsg to the mysubject as string
        end if
    end tell
end repeat
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T11:57:24+00:00Added an answer on June 10, 2026 at 11:57 am

    Ok, The problem was solved by adding

    delay(3)

    right before

    set subject of theMsg to the mysubject as string

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm forced to use IE7 at work, and have just discovered that the MiniProfiler
I am forced to use VS2008 for the bulk of my projects at work,
In classic ASP (which I am forced to use), I have a few factory
I have a project, where I'm forced to use ftp as a means of
I have a flexgrid that I'm forced to use. Thing is that when i
I have been forced to use !important in css. There is probably another way
I am trying to setup RInside at work where we are forced to use
I'm forced to use Visual Source Safe 2005 at work. I'd like to combine
I have a user base that is forced to use IE 7. I have
I'm forced to use stone knives and bear skins at work and unfortunately LINQ

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.