More Outlook Resource Sites

Microsoft Developer Network (MSDN)

FAQs and other general resources

Login

login
password
Remember me

You will need to register and log in if you want to download the source code for the Microsoft Outlook Programming book. The forums and code sharing areas are open to both registered and non-registered visitors.

share code 02-Sep-2010 22:23

Looking for help with Outlook programming projects — VSTO, add-ins, VBA, custom Outlook forms, etc.? You′ve come to the right place!

NEW! >> Subscribe to this site via RSS. For more RSS options, see the complete list of feeds on our main news page.

 

Code level: advanced    Code area: Outlook and .NET Printer Friendly Version
Title: C# AddIn: HowTo implement BusinessRules
Description: C# sample AddIn that demonstrates a way how to enforce business rules on outlook items
Date: 27-Aug-2006  06:35
Code level: advanced
Code area: Outlook and .NET
Posted by: Helmut Obertanner
Body:
All 3comments
Page [ 1  
  19-Sep-2006  12:53   
While running this code in debug mode, I came across a flaw. The error that I'm wondering about might be more of a glitch in Outlook though. If you run this code and go to the "Contacts" folder, then in the pane on the right-side, edit a contact so that the CompanyName is less than 3 characters. You will receive the error alert [as you should], however, Outlook leaves the newly typed [bad] CompanyName in the field until the user exits the Contact folder and goes back in.

Is there a way to avoid this "glitch"? I am trying to write a program so that the user cannot edit the contact from the "listview" grid in Outlook pane.

Any help would be greatly appreciated!
  28-Sep-2006  16:16   
Hello Mike,

 Sorry I didn't know a way how to prevent an user to edit an outlook item directly in the listview. No Idea. Maybe with the SelectionChanged event discar the changes or something.

Greets, Helmut
  12-Jun-2007  13:44   
This works very well, but I'd like to know how it is possible to catch the selection of category ? When I select an appointment its okay, but when I select the entire category, the Explorer.Selection collection is empty. Any ideas ?
Page [ 1  
Post your comment



name        email