![]() |
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. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form.
I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
Ads |
#3
|
|||
|
|||
![]()
Thanks for your reply Sue! I am trying to develop a Form with dates for
staff's Holiday, so staff can download the form from our Intranet, fill out the form, then vb code validates the data then sends the mail to the recipient, then on vote approval adds the dates to the company' s holiday calendar. A vote option confirms yes or no and a reply is emailed. My custom form object isn't shown in the IDE. Project1 is the root node, then there's an Outlooksession, then a node called Module1. If I add a form in the IDE then everything is as expected for that form object, but it’s not linked to the parent. the two entities (VB IDE) and my form aren't connected. I want to work on the custom form object's controls - i.e a textbox in the IDE. Not the Outlook Program. The textbox doesn’t exist, nor does my form. To make things more strange when I choose Tools - view code I can write script in there. How comes I can't see or edit this in the IDE? Why is the program raising an "object required" exception, when executing the TextBox10.Text statement? TextBox10 is on the damn form! Sub CommandButton1_Click() Set Word = Application.CreateObject("Word.Application") Word.Visible = True Word.Documents.Open ("C:\a.doc") TxtBoxCheck() End Sub sub TxtBoxCheck() TextBox10.Text = "balls" end sub Good news we are finishing early to work the England game. All answers welcome! "Sue Mosher [MVP-Outlook]" wrote: Code behind an Outlook custom form is VBScript and is added through the form design code window. A text box fires no events. Also note that custom message forms are often a bad idea. What is it that you're trying to accomplish? The article at http://msdn.microsoft.com/library/en...hatsNew2k3.asp shows how to write to a SharePoint contacts list. Writing to an events list would be similar. -- 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 "A Reno" A wrote in message ... Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form. I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
#4
|
|||
|
|||
![]()
so staff can download the form from our Intranet, fill out
the form, then vb code validates the data Are you using Exchange as your mail server? Do you have permission to publish the form to the Organizational Forms library? If the answer to both question is not Yes, you're going to have a very difficult time getting an Outlook message form with code behind it to work. My custom form object isn't shown in the IDE That's to be expected. As I said, custom form code is VBScript entered in the Outlook form designer's code window. It has nothing at all to do with the VBA IDE (although many of us use VBA to prototype code for eventual porting to VBScript). In general, you will refer to custom form controls only when you want to change the look of those controls or handle a Click event. The data is stored in Outlook properties and you should refer to those properties directly, using the syntax described at http://www.outlookcode.com/d/propsyntax.htm Enjoy the game! -- 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 "A Reno" wrote in message ... Thanks for your reply Sue! I am trying to develop a Form with dates for staff's Holiday, so staff can download the form from our Intranet, fill out the form, then vb code validates the data then sends the mail to the recipient, then on vote approval adds the dates to the company' s holiday calendar. A vote option confirms yes or no and a reply is emailed. My custom form object isn't shown in the IDE. Project1 is the root node, then there's an Outlooksession, then a node called Module1. If I add a form in the IDE then everything is as expected for that form object, but it’s not linked to the parent. the two entities (VB IDE) and my form aren't connected. I want to work on the custom form object's controls - i.e a textbox in the IDE. Not the Outlook Program. The textbox doesn’t exist, nor does my form. To make things more strange when I choose Tools - view code I can write script in there. How comes I can't see or edit this in the IDE? Why is the program raising an "object required" exception, when executing the TextBox10.Text statement? TextBox10 is on the damn form! Sub CommandButton1_Click() Set Word = Application.CreateObject("Word.Application") Word.Visible = True Word.Documents.Open ("C:\a.doc") TxtBoxCheck() End Sub sub TxtBoxCheck() TextBox10.Text = "balls" end sub Good news we are finishing early to work the England game. All answers welcome! "Sue Mosher [MVP-Outlook]" wrote: Code behind an Outlook custom form is VBScript and is added through the form design code window. A text box fires no events. Also note that custom message forms are often a bad idea. What is it that you're trying to accomplish? The article at http://msdn.microsoft.com/library/en...hatsNew2k3.asp shows how to write to a SharePoint contacts list. Writing to an events list would be similar. "A Reno" A wrote in message ... Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form. I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
#5
|
|||
|
|||
![]()
Yes, I am running an exchange server, but didn't anticipate I would need to
publish forms in particular locatation. Thanks for the info. Is there a major limit to what can be addressed? For example its possible to add a command button event and script which can't change the name of the caption on the command button because the object can't be resolved. Which explains why the textbox can't do anything useful either? (see below) ------------------------------------------------------------------------------------------------- "Sue Mosher [MVP-Outlook]" wrote: so staff can download the form from our Intranet, fill out the form, then vb code validates the data Are you using Exchange as your mail server? Do you have permission to publish the form to the Organizational Forms library? If the answer to both question is not Yes, you're going to have a very difficult time getting an Outlook message form with code behind it to work. My custom form object isn't shown in the IDE That's to be expected. As I said, custom form code is VBScript entered in the Outlook form designer's code window. It has nothing at all to do with the VBA IDE (although many of us use VBA to prototype code for eventual porting to VBScript). In general, you will refer to custom form controls only when you want to change the look of those controls or handle a Click event. The data is stored in Outlook properties and you should refer to those properties directly, using the syntax described at http://www.outlookcode.com/d/propsyntax.htm Enjoy the game! -- 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 "A Reno" wrote in message ... Thanks for your reply Sue! I am trying to develop a Form with dates for staff's Holiday, so staff can download the form from our Intranet, fill out the form, then vb code validates the data then sends the mail to the recipient, then on vote approval adds the dates to the company' s holiday calendar. A vote option confirms yes or no and a reply is emailed. My custom form object isn't shown in the IDE. Project1 is the root node, then there's an Outlooksession, then a node called Module1. If I add a form in the IDE then everything is as expected for that form object, but it’s not linked to the parent. the two entities (VB IDE) and my form aren't connected. I want to work on the custom form object's controls - i.e a textbox in the IDE. Not the Outlook Program. The textbox doesn’t exist, nor does my form. To make things more strange when I choose Tools - view code I can write script in there. How comes I can't see or edit this in the IDE? Why is the program raising an "object required" exception, when executing the TextBox10.Text statement? TextBox10 is on the damn form! Sub CommandButton1_Click() Set Word = Application.CreateObject("Word.Application") Word.Visible = True Word.Documents.Open ("C:\a.doc") TxtBoxCheck() End Sub sub TxtBoxCheck() TextBox10.Text = "balls" end sub Good news we are finishing early to work the England game. All answers welcome! "Sue Mosher [MVP-Outlook]" wrote: Code behind an Outlook custom form is VBScript and is added through the form design code window. A text box fires no events. Also note that custom message forms are often a bad idea. What is it that you're trying to accomplish? The article at http://msdn.microsoft.com/library/en...hatsNew2k3.asp shows how to write to a SharePoint contacts list. Writing to an events list would be similar. "A Reno" A wrote in message ... Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form. I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
#6
|
|||
|
|||
![]()
its possible to
add a command button event and script which can't change the name of the caption on the command button because the object can't be resolved Did you look at the page I suggested?This will give you the correct syntax for returning a control on an Outlook custom form. It is not the same as the VBA user form syntax. -- 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 "A Reno" wrote in message ... Yes, I am running an exchange server, but didn't anticipate I would need to publish forms in particular locatation. Thanks for the info. Is there a major limit to what can be addressed? For example its possible to add a command button event and script which can't change the name of the caption on the command button because the object can't be resolved. Which explains why the textbox can't do anything useful either? (see below) ------------------------------------------------------------------------------------------------- "Sue Mosher [MVP-Outlook]" wrote: so staff can download the form from our Intranet, fill out the form, then vb code validates the data Are you using Exchange as your mail server? Do you have permission to publish the form to the Organizational Forms library? If the answer to both question is not Yes, you're going to have a very difficult time getting an Outlook message form with code behind it to work. My custom form object isn't shown in the IDE That's to be expected. As I said, custom form code is VBScript entered in the Outlook form designer's code window. It has nothing at all to do with the VBA IDE (although many of us use VBA to prototype code for eventual porting to VBScript). In general, you will refer to custom form controls only when you want to change the look of those controls or handle a Click event. The data is stored in Outlook properties and you should refer to those properties directly, using the syntax described at http://www.outlookcode.com/d/propsyntax.htm "A Reno" wrote in message ... Thanks for your reply Sue! I am trying to develop a Form with dates for staff's Holiday, so staff can download the form from our Intranet, fill out the form, then vb code validates the data then sends the mail to the recipient, then on vote approval adds the dates to the company' s holiday calendar. A vote option confirms yes or no and a reply is emailed. My custom form object isn't shown in the IDE. Project1 is the root node, then there's an Outlooksession, then a node called Module1. If I add a form in the IDE then everything is as expected for that form object, but it’s not linked to the parent. the two entities (VB IDE) and my form aren't connected. I want to work on the custom form object's controls - i.e a textbox in the IDE. Not the Outlook Program. The textbox doesn’t exist, nor does my form. To make things more strange when I choose Tools - view code I can write script in there. How comes I can't see or edit this in the IDE? Why is the program raising an "object required" exception, when executing the TextBox10.Text statement? TextBox10 is on the damn form! Sub CommandButton1_Click() Set Word = Application.CreateObject("Word.Application") Word.Visible = True Word.Documents.Open ("C:\a.doc") TxtBoxCheck() End Sub sub TxtBoxCheck() TextBox10.Text = "balls" end sub Good news we are finishing early to work the England game. All answers welcome! "Sue Mosher [MVP-Outlook]" wrote: Code behind an Outlook custom form is VBScript and is added through the form design code window. A text box fires no events. Also note that custom message forms are often a bad idea. What is it that you're trying to accomplish? The article at http://msdn.microsoft.com/library/en...hatsNew2k3.asp shows how to write to a SharePoint contacts list. Writing to an events list would be similar. "A Reno" A wrote in message ... Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form. I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
#7
|
|||
|
|||
![]()
Excellent, thanks for the useful reference links Sue!
"Sue Mosher [MVP-Outlook]" wrote: its possible to add a command button event and script which can't change the name of the caption on the command button because the object can't be resolved Did you look at the page I suggested?This will give you the correct syntax for returning a control on an Outlook custom form. It is not the same as the VBA user form syntax. -- 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 "A Reno" wrote in message ... Yes, I am running an exchange server, but didn't anticipate I would need to publish forms in particular locatation. Thanks for the info. Is there a major limit to what can be addressed? For example its possible to add a command button event and script which can't change the name of the caption on the command button because the object can't be resolved. Which explains why the textbox can't do anything useful either? (see below) ------------------------------------------------------------------------------------------------- "Sue Mosher [MVP-Outlook]" wrote: so staff can download the form from our Intranet, fill out the form, then vb code validates the data Are you using Exchange as your mail server? Do you have permission to publish the form to the Organizational Forms library? If the answer to both question is not Yes, you're going to have a very difficult time getting an Outlook message form with code behind it to work. My custom form object isn't shown in the IDE That's to be expected. As I said, custom form code is VBScript entered in the Outlook form designer's code window. It has nothing at all to do with the VBA IDE (although many of us use VBA to prototype code for eventual porting to VBScript). In general, you will refer to custom form controls only when you want to change the look of those controls or handle a Click event. The data is stored in Outlook properties and you should refer to those properties directly, using the syntax described at http://www.outlookcode.com/d/propsyntax.htm "A Reno" wrote in message ... Thanks for your reply Sue! I am trying to develop a Form with dates for staff's Holiday, so staff can download the form from our Intranet, fill out the form, then vb code validates the data then sends the mail to the recipient, then on vote approval adds the dates to the company' s holiday calendar. A vote option confirms yes or no and a reply is emailed. My custom form object isn't shown in the IDE. Project1 is the root node, then there's an Outlooksession, then a node called Module1. If I add a form in the IDE then everything is as expected for that form object, but it’s not linked to the parent. the two entities (VB IDE) and my form aren't connected. I want to work on the custom form object's controls - i.e a textbox in the IDE. Not the Outlook Program. The textbox doesn’t exist, nor does my form. To make things more strange when I choose Tools - view code I can write script in there. How comes I can't see or edit this in the IDE? Why is the program raising an "object required" exception, when executing the TextBox10.Text statement? TextBox10 is on the damn form! Sub CommandButton1_Click() Set Word = Application.CreateObject("Word.Application") Word.Visible = True Word.Documents.Open ("C:\a.doc") TxtBoxCheck() End Sub sub TxtBoxCheck() TextBox10.Text = "balls" end sub Good news we are finishing early to work the England game. All answers welcome! "Sue Mosher [MVP-Outlook]" wrote: Code behind an Outlook custom form is VBScript and is added through the form design code window. A text box fires no events. Also note that custom message forms are often a bad idea. What is it that you're trying to accomplish? The article at http://msdn.microsoft.com/library/en...hatsNew2k3.asp shows how to write to a SharePoint contacts list. Writing to an events list would be similar. "A Reno" A wrote in message ... Hi I'm new to Outlook programming. I'm working on a custom Outlook 2003 Form. I have added textbox controls to Form but can't get the control to do anything useful. I want to link some code to the control, but in the VBA project the controls aren't included. Also how can I tell if i'm writting a macro (script -VBA?) or sub routines (native VB?) and how do i link them to a control or event other than Outlook application events? Basically I only want the functionality when the form (email msg class) executes not whenever Outlook launches. Also I've been asked to update a sharepoint calander via this forms input is that possible? All suggestion welcome Cheers |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Active X Controls in Forms | Oliver Gräser | Outlook - Using Forms | 6 | June 11th 06 06:06 PM |
Event handling? | [email protected] | Add-ins for Outlook | 0 | January 25th 06 01:40 PM |
Event handling? | [email protected] | Add-ins for Outlook | 0 | January 25th 06 01:40 PM |
Handling Task Item Delete Event | AtulSureka | Outlook - Using Forms | 0 | January 24th 06 10:25 AM |
How to handling Custom Form Control Event in VB Com Add-In? | Raphaël ZHOU \(Jadiam\) | Outlook - Using Forms | 1 | January 11th 06 07:31 AM |