>> a Post item now an Appointment

J

Jonathan Parminter

Hi, this is a problem that I have posted before. But I'm
hoping new information will jog someone's memory/intuition
to provide a resolution...

Situation: I have a custom appointment for a public
calendar folder. To ensure appointments are only available
on specific days and times, I have a userform within an
excel spreadsheet run a procedure to create appointments
in this public folder. Users of appointments in the public
calendar folder can only edit existing appointments.

Problem: when an appointment that was created by the excel
userform (in Outloook it has never been opened, edited and
saved) the vbscript code behind the form (for example
Item_CustomPropertyChange(ByVal Name) works the first time
the form is opened. But once form is closed, vbscript code
behind form no longer runs when the form is opened a
second time to make further changes.

Question: why does code work while the form is open the
first time after it was created using vba; but not any
other time that the form is opened for editing?

I have just noticed that when I change the current view
to 'By Category' the icon for original items created using
vba is a 'Post' icon. Whereas once an item has been
opened, edited and saved the icon changes to
an 'Appointment' icon. This may be significant, I just
don't know what to do next!

Any ideas or suggestions appreciated :)

Cheers
Jonathan
 
S

Sue Mosher [MVP]

Question: why does code work while the form is open the
first time after it was created using vba; but not any
other time that the form is opened for editing?

Because you've done something to one-off the form, which means it will no
longer run code. See http://www.slipstick.com/outlook/esecup.htm#formsec and
http://www.slipstick.com/dev/formpub.htm#oneoff for more on this issue. I'd
look at the script for causes. The change of icon from your custom form's
icon to that of a normal appointment is another symptom of one-offing.
--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
J

Jonathan Parminter

Once again thanks Sue. This has been bugging me for a
while now. If you ever visit New Zealand let me know :)

Cheers
Jonathan
 
S

Sue Mosher [MVP]

Actually, I'm hoping to visit NZ July or August of 2005 as a high school
graduation present for my daughter (and an excuse to use up the bulk of my
frequent flyer miles).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top