Outlook Banter

Outlook Banter (http://www.outlookbanter.com/)
-   Outlook and VBA (http://www.outlookbanter.com/outlook-vba/)
-   -   HELP! Custom Form Events (http://www.outlookbanter.com/outlook-vba/46909-help-custom-form-events.html)

John Lane April 25th 07 07:12 PM

HELP! Custom Form Events
 
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if


Sue Mosher [MVP-Outlook] April 25th 07 08:19 PM

HELP! Custom Form Events
 
Code runs only on published forms, not on items created with an .oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if


John Lane April 25th 07 09:38 PM

HELP! Custom Form Events
 
So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an .oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if



Sue Mosher [MVP-Outlook] April 26th 07 04:15 AM

HELP! Custom Form Events
 
Export? Sorry, I don't know what you mean in this context.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an .oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if



John Lane April 26th 07 02:36 PM

HELP! Custom Form Events
 
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

"Sue Mosher [MVP-Outlook]" wrote:

Export? Sorry, I don't know what you mean in this context.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an .oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if




Sue Mosher [MVP-Outlook] April 26th 07 03:27 PM

HELP! Custom Form Events
 
Code will run only on items created from a published form. I don't see how Save As fits into your scenario.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an ..oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if




John Lane April 26th 07 07:22 PM

HELP! Custom Form Events
 
Well, I publish it, then save it to the .oft file. It was the only way I
could figure out
how to make an .oft file out of the published form. But you're right, it
didn't work. And in corporate America, user departments don't have the
permission to publish a form to a public folder.

"Sue Mosher [MVP-Outlook]" wrote:

Code will run only on items created from a published form. I don't see how Save As fits into your scenario.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an ..oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if





Sue Mosher [MVP-Outlook] April 26th 07 10:30 PM

HELP! Custom Form Events
 
Saving it to the .oft file makes a backup copy of the published form, but doesn't give you anything to put into production. What you must use to create new items is the published form. If you can't publish it to an appropriate location (and we don't know what that is, because you haven't said what kind of form it is), then an Outlook custom form is not a viable solution for your scenario (which you also haven't described).

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Well, I publish it, then save it to the .oft file. It was the only way I
could figure out
how to make an .oft file out of the published form. But you're right, it
didn't work. And in corporate America, user departments don't have the
permission to publish a form to a public folder.

"Sue Mosher [MVP-Outlook]" wrote:

Code will run only on items created from a published form. I don't see how Save As fits into your scenario.



"John Lane" wrote in message ...
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an ...oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if





John Lane April 27th 07 02:38 PM

HELP! Custom Form Events
 
I thought forms could only be published to Exchange folders. Can they be
published to a file system file? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Saving it to the .oft file makes a backup copy of the published form, but doesn't give you anything to put into production. What you must use to create new items is the published form. If you can't publish it to an appropriate location (and we don't know what that is, because you haven't said what kind of form it is), then an Outlook custom form is not a viable solution for your scenario (which you also haven't described).

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
Well, I publish it, then save it to the .oft file. It was the only way I
could figure out
how to make an .oft file out of the published form. But you're right, it
didn't work. And in corporate America, user departments don't have the
permission to publish a form to a public folder.

"Sue Mosher [MVP-Outlook]" wrote:

Code will run only on items created from a published form. I don't see how Save As fits into your scenario.



"John Lane" wrote in message ...
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an ...oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if






Sue Mosher [MVP-Outlook] April 27th 07 04:18 PM

HELP! Custom Form Events
 
No, forms can be published to the user's Personal Forms library, the organization's Organizational Forms library on the Exchange Server, or to a folder. Saving a form as an .oft file is not publishing it. Only published forms should be used to create new items. .oft files can server as backup copies of published forms.
--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"John Lane" wrote in message ...
I thought forms could only be published to Exchange folders. Can they be
published to a file system file? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Saving it to the .oft file makes a backup copy of the published form, but doesn't give you anything to put into production. What you must use to create new items is the published form. If you can't publish it to an appropriate location (and we don't know what that is, because you haven't said what kind of form it is), then an Outlook custom form is not a viable solution for your scenario (which you also haven't described).

"John Lane" wrote in message ...
Well, I publish it, then save it to the .oft file. It was the only way I
could figure out
how to make an .oft file out of the published form. But you're right, it
didn't work. And in corporate America, user departments don't have the
permission to publish a form to a public folder.

"Sue Mosher [MVP-Outlook]" wrote:

Code will run only on items created from a published form. I don't see how Save As fits into your scenario.



"John Lane" wrote in message ...
Sorry. Meant "Save As" on the File pull down. Thanks for the heads up on
forms. Was in here as I was fooling with VB, so figured this was the place to
put my question.

So will code run if I publish it then export it? Thanks.

"Sue Mosher [MVP-Outlook]" wrote:

Code runs only on published forms, not on items created with an ...oft file.

Item is an intrinsic object in Outlook form VBScript code.

FYI, there is a newsgroup specifically for Outlook forms issues "down the hall" at microsoft.public.outlook.program_forms or, via web interface, at http://www.microsoft.com/office/comm...rogram_f orms

"John Lane" wrote in message ...
Below is code I have in a custom Outlook (2003) form but it doesn't fire
when I change or click into the Subject field or any field. Does "Item" have
to be defined or something? I followed the example in KB article 171246. The
form is invoked from an .oft file. The code was inserted in the Script Editor.
Thanks.

Sub Item_PropertyChange (ByVal myPropertyName)
msgbox "here1"
If myPropertyName = "Subject" then
msgbox "hello - Subject"
End if




All times are GMT +1. The time now is 09:13 AM.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com