Discussion Locked

Outlook Programing

0 helpful
3 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I need to know how I can access a field on one form and use the value on another.
I am making a appointment form to go with a contact management program that is made in Outlook. What I want to do is use a value from a field on one form as the default value on the location field on the appointment form. Both forms are in the same folder. How do I add a value from a field. In VB I would
strSomething = formName.txtName.txt
and that would assighn the value from the text box to the string something. How do I do it in the Outlook script editor, That is VBscript isin't it.
Dennis

3 replies

by suemvp

Yes, Outlook uses VBScript as the language for the code behind Outlook forms. In general, you use property names -- e.g. Item.Subject or Item.UserProperties("My custom field") -- for bound controls and properties that aren't visible on the form. Usecontrol values only for unbound controls. See http://www.slipstick.com/dev/propsyntax.htm for details.

The current item -- i.e., the one in whose form the code is running -- is an intrinsic Outlook object, Item.

How you get the other appointment as an object will depend on whether you're creating it from within the current item or you need to locate it in the folder based on some criteria.

This discussion is closed to new replies.