View Single Post
  #1  
Old October 30th 07, 09:10 AM posted to microsoft.public.outlook.program_forms
Oskar Vaia
external usenet poster
 
Posts: 29
Default Outlook 2003: Personalized form with VB-Script and VB.NET

Hi,

in my own personalized task-form i have amongst others some VB-Script-code
for the "Item_CustomPropertyChange"-event.
This event will triggered when i insert or change values on my custom-fields
on the personalized task-form and this is right.

An application, which i have developed with VB.NET 2005 inserts or changes
values on the custom-fields on the personalized task-form, too.

Here the VB.NET-code:
---
Dim myOlApp As New Outlook.Application
Dim myNamespace As Outlook.NameSpace
Dim myitem As Outlook.TaskItem
myNamespace = myOlApp.GetNamespace("MAPI")
myitem = myNamespace.GetItemFromID(strEntryID, objStoreID)
myitem.UserProperties("MB1").Value = True
myitem.Save()
myNamespace = Nothing
myOlApp = Nothing
---

Now my question:
When my VB.NET-application inserts or changes values on the custom-fields on
the personalized task-form, then the VB-Script code behind the taskform will
triggered, too. It is possible to prevent this comportment?
The VB-Script code behind the taskform should only triggered when i insert
or change values on my taskform directly.

thx & bye

Oskar

Ads