Warning message

Status
Not open for further replies.
T

Thomy

Hello.

I am trying to personalize my Outlook to avoid sending useless e-mails.

For instance, since I have no knowledge of Visual Basic, I have found on

the web the following script to avoid sending e-mails with no subject:

Private Sub Application_ItemSend(ByVal Item As Object, Cancel As

Boolean)

Dim strSubject As String

strSubject = Item.Subject

If Len(strSubject) = 0 Then

Prompt$ = "Subject not present, continue?"

If MsgBox(Prompt$, vbYesNo + vbQuestion + vbMsgBoxSetForeground, "Check

for Subject") = vbNo Then

Cancel = True

End If

End If

End Sub

It works fine. Now I would like something different:

I would like a similar warning when I am trying to send an e-mail

without attachment to more then, let’s say, 8 addresses. The idea is

that when I send an e-mail to several recipients I usually have to

attach something, so this would be a valuable warning to avoid

forgetting it.

Can you help?

Thanks,

Tom

Thomy
 

Michael Bauer

Senior Member
Outlook version
Outlook 2010 32 bit
Email Account
Exchange Server
For that use the same event. See the Item.Attachments collection, if its

Count property is 0, there's no attachment.

Best regards

Michael Bauer

Am Mon, 10 May 2010 13:31:19 +0100 schrieb Thomy:


> Hello.

> I am trying to personalize my Outlook to avoid sending useless e-mails.
> For instance, since I have no knowledge of Visual Basic, I have found on
> the web the following script to avoid sending e-mails with no subject:
> Private Sub Application_ItemSend(ByVal Item As Object, Cancel As
> Boolean)
> Dim strSubject As String
> strSubject = Item.Subject
> If Len(strSubject) = 0 Then
> Prompt$ = "Subject not present, continue?"
> If MsgBox(Prompt$, vbYesNo + vbQuestion + vbMsgBoxSetForeground, "Check
> for Subject") = vbNo Then
> Cancel = True
> End If
> End If
> End Sub

> It works fine. Now I would like something different:
> I would like a similar warning when I am trying to send an e-mail
> without attachment to more then, let’s say, 8 addresses. The idea is
> that when I send an e-mail to several recipients I usually have to
> attach something, so this would be a valuable warning to avoid
> forgetting it.

> Can you help?

> Thanks,

> Tom
 
T

Thomy

Thank you Michael.

I can guess that the logic to use is the one you have suggested. The

problem is that, with no programming knowledge, I lack the right

syntax.

Is someone willing to compose something for me?

Thanks again.

Tom

'Michael Bauer [MVP - Outlook Wrote:
> ;348672']For that use the same event. See the Item.Attachments
> collection, if its
> Count property is 0, there's no attachment.

> > Best regards
> Michael Bauer
> Category Manager -

> SAM - The Sending Account Manager:
> http://www.vboffice.net/product.html?lang=en
>


Thomy
 

Michael Bauer

Senior Member
Outlook version
Outlook 2010 32 bit
Email Account
Exchange Server
You might also look on www.slipstick.com. There're are ready-to-use Addins

for that available.

Best regards

Michael Bauer

Am Tue, 11 May 2010 10:26:59 +0100 schrieb Thomy:


> Thank you Michael.
> I can guess that the logic to use is the one you have suggested. The
> problem is that, with no programming knowledge, I lack the right
> syntax.
> Is someone willing to compose something for me?

> Thanks again.

> Tom

> 'Michael Bauer [MVP - Outlook Wrote:
> > ;348672']For that use the same event. See the Item.Attachments
> > collection, if its
> > Count property is 0, there's no attachment.
>

>> > > Best regards
> > Michael Bauer
> > Category Manager -

> > SAM - The Sending Account Manager:
> > http://www.vboffice.net/product.html?lang=en
> >
 
Status
Not open for further replies.
Similar threads
Thread starter Title Forum Replies Date
Diane Poremsky Meeting Location Warning Message Using Outlook 0
C WARNING - DO NOT USE AN OUTLOOK.COM ADDRESS FOR GOOGLE ACCOUNT RECOVERY EMAIL Using Outlook 10
A Warning When Opening attachment Using Outlook 7
M warning for too many appointments on a same day in Outlook Using Outlook 1
J Customize Attachement Security Warning Using Outlook 1
D Conflict warning while editing Exchange Server Administration 0
Diane Poremsky Disable the Unsafe Hyperlink Warning when Opening Attachments Using Outlook 0
Jack Poore Outlook gives warning using GO Contracts Sync Mod Using Outlook 4
M Rule to pop a warning dialogue on certain actions Using Outlook 1
Rory Campion Not getting a warning when a shared calendar item has been updated by someone else Using Outlook 2
B How do I get a warning before deleting e-mail messages? Using Outlook 2
J Disable outlook 2010 no-subject warning Using Outlook 4
E Disable outlook 2010 no-subject warning Using Outlook 9
T Missing attachment warning Outlook VBA and Custom Forms 1
F No Attachment Warning - VBA Code HELP Outlook VBA and Custom Forms 1
T How to get MailItem.Body without security warning in Outlook 2010 Outlook VBA and Custom Forms 2
H How turn off outlook security warning dialog box from outlook Outlook VBA and Custom Forms 1
P Stopping that security warning Outlook VBA and Custom Forms 1
1 Warning messege Outlook VBA and Custom Forms 3
O How to find and replace a word in Outlook-Agenda-Subject and Message? Using Outlook 0
X Open Hyperlinks in an Outlook Email Message (Help with Diane's solution) Outlook VBA and Custom Forms 3
Commodore Unable to move message Using Outlook 3
Y Disable Microsoft Outlook Test Message Using Outlook 5
S Unable to change Message Class Outlook VBA and Custom Forms 0
S Changing Message Class Outlook VBA and Custom Forms 4
Cathy Rhone Mail merge error message Using Outlook 2
C Can't Locate an Unread Message in my Outlook view pane Using Outlook 0
G Send a greeting message to a contact on birthday Outlook VBA and Custom Forms 5
B Inconsistent handling of message read/unread status by Outlook Using Outlook 3
N Save Selected Email Message as .msg File Outlook VBA and Custom Forms 12
T Macro to move reply and original message to folder Outlook VBA and Custom Forms 6
O Outlook 2010 Add delete button to the side of the message list Using Outlook 1
Cathy Rhone The properties of the message have been changed Using Outlook 1
S Outlook 2016 A Shortcut to recall and delete and sent message. Using Outlook 1
T vba extract data from msg file as attachment file of mail message Outlook VBA and Custom Forms 1
S Unable to extract text from an Outlook email message Using Outlook 2
R Outlook 2016 Message-ID oddity/inconsistency? Using Outlook 7
J Implement Keywords based on body message Outlook VBA and Custom Forms 0
C must select message to trigger safe list Using Outlook 3
witzker HowTo Change message Class of contact form Outlook VBA and Custom Forms 0
D.Moore VB script to Digitaly Sign newly created outlook message Outlook VBA and Custom Forms 2
O VBA Outlook Message Attachment - Array Index Out of Bounds Outlook VBA and Custom Forms 0
W September 2020 - No Default Email Client message after Office Update Using Outlook 1
A Flag Message for Follow Up after sending Outlook VBA and Custom Forms 1
S Outlook (2016 32bit; Gmail IMAP) - Save sent message to Outllook Folder Outlook VBA and Custom Forms 0
C Why won't Title display in message list? Using Outlook 1
icacream content in this message could not be downloaded.... Using Outlook 2
J Outlook 2016 After a search in all mailboxes, where is each message that was found? Using Outlook 6
R Warn before sending message Outlook VBA and Custom Forms 4
T Column to display which email alias a message was sent to Outlook VBA and Custom Forms 6

Similar threads

Top