A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook - General Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Is it possible to create and publish Outlook Custom Form through VBA



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old March 10th 06, 10:40 AM posted to microsoft.public.outlook
[email protected]
external usenet poster
 
Posts: 5
Default Is it possible to create and publish Outlook Custom Form through VBA

Hi All,
I have created COM-Addin for Outlook in VB. But there are lot of
limitations in VBScript like to handle all events(other than click
event) of controls(ListView,Textbox) on outlook custom form. Can we
handle these events using VBA so that i can distribute that
application? Or Is it possible to create and publish that form through
VB.?

Thanks,

  #2  
Old March 10th 06, 03:18 PM posted to microsoft.public.outlook
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Is it possible to create and publish Outlook Custom Form through VBA

You can certainly create your own VB forms that will give you a full set of
events but you cannot extend the events that you receive in a form's
controls from an addin. You would still only get Click and that would be
fired in the VBScript code.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


wrote in message
oups.com...
Hi All,
I have created COM-Addin for Outlook in VB. But there are lot of
limitations in VBScript like to handle all events(other than click
event) of controls(ListView,Textbox) on outlook custom form. Can we
handle these events using VBA so that i can distribute that
application? Or Is it possible to create and publish that form through
VB.?

Thanks,


  #3  
Old March 10th 06, 03:38 PM posted to microsoft.public.outlook
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default Is it possible to create and publish Outlook Custom Form through VBA

Actually, I think all the control events may be available. I posted this little VBA snippet at http://www.outlookcode.com/threads.a...essageid=16824 and I get both Change and Click events firing from a custom form item checkbox, regardless of whether it's bound or unbound. I think that's also the technique that BCM add-in uses.

Dim WithEvents chk1 As MSForms.CheckBox

Sub initChk1()
Set chk1 = Application.ActiveInspector.CurrentItem. _
GetInspector.ModifiedFormPages("General").Controls ("CheckBox1")
End Sub

Private Sub chk1_Change()
MsgBox "Change"
End Sub

Private Sub chk1_Click()
MsgBox "Click"
End Sub

--
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


"Ken Slovak - [MVP - Outlook]" wrote in message ...
You can certainly create your own VB forms that will give you a full set of
events but you cannot extend the events that you receive in a form's
controls from an addin. You would still only get Click and that would be
fired in the VBScript code.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


wrote in message
oups.com...
Hi All,
I have created COM-Addin for Outlook in VB. But there are lot of
limitations in VBScript like to handle all events(other than click
event) of controls(ListView,Textbox) on outlook custom form. Can we
handle these events using VBA so that i can distribute that
application? Or Is it possible to create and publish that form through
VB.?

Thanks,


  #4  
Old March 10th 06, 09:25 PM posted to microsoft.public.outlook
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Is it possible to create and publish Outlook Custom Form through VBA

Ah, OK, you're essentially subclassing the controls that way. That should
work, good thinking Sue. The only caveat is that some of the MSForms
controls don't like being used in VB so they might not like VBA either.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Sue Mosher [MVP-Outlook]" wrote in message
...
Actually, I think all the control events may be available. I posted this
little VBA snippet at
http://www.outlookcode.com/threads.a...essageid=16824 and I get
both Change and Click events firing from a custom form item checkbox,
regardless of whether it's bound or unbound. I think that's also the
technique that BCM add-in uses.

Dim WithEvents chk1 As MSForms.CheckBox

Sub initChk1()
Set chk1 = Application.ActiveInspector.CurrentItem. _
GetInspector.ModifiedFormPages("General").Controls ("CheckBox1")
End Sub

Private Sub chk1_Change()
MsgBox "Change"
End Sub

Private Sub chk1_Click()
MsgBox "Click"
End Sub

--
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

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA shortcut to open custom form in design mode? Burma Jones Outlook and VBA 4 March 30th 06 11:37 AM
Is it possible to create and publish Outlook Custom Form through VBA [email protected] Outlook - General Queries 1 March 10th 06 02:51 PM
VBA shortcut to open custom form in design mode? Burma Jones Outlook - Using Forms 2 March 6th 06 07:17 PM
Delete Custom Outlook Control thru Access VBA Sue Mosher [MVP-Outlook] Outlook - Using Forms 0 January 20th 06 05:29 PM
Can't publish new form to Organizational Forms Library Andrew Vital Outlook and VBA 4 January 20th 06 04:42 PM


All times are GMT +1. The time now is 05:10 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-2025 Outlook Banter.
The comments are property of their posters.