Info Wwk
Figure 1.10 - The VBScript Samples folder. This document was created by an unregistered ChmMagic, please go to http www.bisenter.com to register it. T For additional information about the types of applications you can create, visit the following Web sites http www. slipstick. com addins mssampleapps. htm http msdn. microsoft, com office Microsoft Outlook offers easy-to-use design tools for creating custom forms and folders. For example, in Design mode, Outlook provides an AutoLayout feature...
Testing
Figure 11.8 - The Testing command bar. The code required to create Testing is relatively straightforward. It's presented in sections so that you can clearly understand each step of the coding process. The first order of business is to instantiate a CommandBar object so that controls can be added to the command bar's CommandBarControls collection. The next line attempts to instantiate a Testing CommandBar object from the Explorer's Command Bars collection. If Testing already exists and no error...
I Wft
Figure 15.12 - Use the Administration Dashboard to create My Dashboard Creating a Nested Dashboard One great feature of Digital Dashboards is that they can be nested. In this case, you will create a child Dashboard named Northwind Dashboard under My Dashboard. To create the Northwind Dashboard 1. In the Administration page, click My Dashboard in the Dashboard View Web Part. 2. Enter Northwind Dashboard as the name and title of the Dashboard, as shown in Figure 15-13. 3. Click the Save button in...
Info Agn
Applications ffi Beta Contact Eusiness Can Call List Classified Ad' Discussions eBusiness Exchange Oi. Internet Ne Job Candidat l.ist5erverAD Micro Eye Micro Eye Te Microsoft Art My Adnninistr My Contacts My Discussior My Team Cor T Exchange Outlook Development Search Categories Docurnent Librar MSDN Online Exchange Developer Center Dev Discussions Siipstick Systems Outlook amp Exchange Solutions Center Using Quick Links Using Categories This site contains white papers, sample codi technical...
The Package and Deployment Wizard
Once you have developed, debugged, and secured your COM Add-in, you can create an installation setup program with either the Setup Wizard, if you are using Visual Basic 5, or the Package and Deployment Wizard if you are using Visual Basic 6. If you use the Visual Basic 5 Setup Wizard, you must add code to the setup program to ensure that the correct registry settings will be created for your Add-in. See Add-In Registration earlier in this chapter for the correct registry key names and values...
Info Gvq
Unlike previous versions of Outlook, Outlook 2000 and 2002 allow you to write VBA or Visual Basic code to respond to all the events that are raised in a Message item. For additional information, see Chapter 9 and Chapter 14. Mailltem and Postltem Objects Properties This section covers the Getlnspector, Body, HTMLBody, To, and SenderName properties of the Mailltem and Postltem objects. Using Getlnspector To Reference the Form You can use the Getlnspector property of the Mailltem object or the...
Info Qhq
Figure 2.5 - The Script Editor window shows the item_Open function. For more information about using VBScript, see Chapter 11, Using Visual Basic, VBA, or VBScript with Outlook. With Outlook, you can create custom views by adding, removing, and rearranging fields in the Column Heading row of the folder. For example, you can create a column by dragging a field from the Field Chooser to the Column Heading row. To add or remove a column using the Field Chooser 1. Select a folder on the Folder...
Chapter The Northwind Contact Management Application
The Northwind Contact Management application uses the Microsoft Access 2002 Northwind sample database to populate a set of folders that showcase the contact management features of Microsoft Outlook 2002. Of course, every user has the ability to manage his own contacts using the Contacts folder in his personal mailbox. However, organizations need to manage and share contact information beyond the confines of their users' personal contact lists. Outlook 2002 improves upon the ability of previous...
Displaying the List of COM Addlns
Outlook's COM Add-lns dialog box shown in Figure 14-2 is buried deep in the Tools Options dialog box. If you are developing COM Add-ins, you'll want to customize your Standard or Advanced Explorer toolbar and place a command bar button on the toolbar to provide a shortcut to the COM Add-lns dialog box. Add-lns available Items Command 3ar Outlook 2000 Team Folders Wizard 9,0,0,3217 Outlook Shared Activities Add-In P Outiook today Add-In Location C Program Files ZipOut
Ok 1
Location D WINNT System32 COMCT332.00i Figure 5.19 - You can add additional controls to the Outlook Control Toolbox by using the Custom Controls command and selecting controls in the Additional Controls dialog box. To add additional controls to the Control Toolbox 1. Right-click the bottom of the Controls page in the Control Toolbox, and then click Custom Controls on the shortcut menu. 2. Under Available Controls, click the controls you want to enable, and then click OK. To add a control to a...
MAPIFolder Object Properties
This section covers the DefaultMessageClass, FolderPath, Folders, InAppFolderSyncObject, Items, Parent, Child, EntrylD, StorelD, UnReadltemCount, and WebViewURL properties. The Folders property is useful for accessing a folder in the folder list. The Items property is useful for retrieving a collection of items in the folder. Referencing a Folder in the Folder List You can use the Folders property with the MAPIFolder object to return another MAPIFolder object. The OpenMAPIFolder function shown...
Info Nez
Compare the most recently typed letter to the first letter of each entry in the list. The first match in the list is selected. Compare the user's entry and an exact match in an entry from the list. The matching feature resets after two seconds six seconds in the Far East version . For example, if you have a list of the 50 United States and you type CO quickly, you will find Colorado. If it takes you longer than two seconds to type CO, however, you will find Ohio first because the auto-complete...
Publish the Form
When you finish designing a form, you publish it to a forms library. Optionally, you can make a backup copy of the form, although it is not required. When you publish a form, you register the form in a forms library and expose the form to the Outlook user interface. For example, after the form is published, the form menu commands and form name are visible in the Outlook user interface. When you make a backup copy of the form, you save the form definition as an Outlook Form Template or .oft...
Info Ptk
Figure 15.14 - The My Dashboard Content page Figure 15.14 - The My Dashboard Content page Figure 15.15 - The Layout page for My Dashboard allows you to customize the arrangement of your Web Parts To add Web Parts to Northwind Dashboard Figure 15.15 - The Layout page for My Dashboard allows you to customize the arrangement of your Web Parts To add Web Parts to Northwind Dashboard 1. Launch Internet Explorer, and type the following URL in the Address Bar htt p lt s ervername gt Dash board dash...
Visible False End With End Sub
The Deactivate event occurs when the Inspector window ceases to be the active window because of a user action or program code. The same cautions mentioned earlier regarding the Deactivate event of the Explorer window apply to the Inspector window. Do not display user interface elements in the Deactivate event procedure. The following procedure hides the built-in Clipboard Command bar. In the Deactivate event, you cannot use the Currentltem property to return properties of the item. If you...
Tools to Create Folder Home Pages
To create folder home pages, you can use any of the tools listed next. If you become a serious folder home page developer, you will use a combination of these tools or maybe a third-party authoring tool not listed in the following table. If you want to customize your folder home pages, you should consider Microsoft Visual Studio 98 Professional, Visual Studio 98 Enterprise edition, or a later version as the tool of choice. Because Visual Studio ships with both Visual Basic and Visual InterDev...
OptionsPagesAdd
Oddly enough, the NameSpace object supports only one event, the OptionsPagesAdd event. This event is the first cousin of the OptionsPagesAdd event for the Application object. OptionsPagesAdd for the NameSpace object occurs before a Folder Properties dialog box is displayed for a folder. The folder for which the Folder Properties dialog box is displayed is then passed as a MAPI Folder object to the event procedure for OptionsPagesAdd. You can use the OptionsPagesAdd event of the NameSpace object...
Extending Your Application with Public Methods
The basic functionality of the Outlook Shared Activities COM Add-in centers around the addition of an Explorer toolbar. In this respect, this add-in is typical. However, it has some special features that allow you to extend your application beyond the addition of Explorer toolbars. For example, VBScript code behind forms cannot make Windows API calls. The Outlook Shared Activities COM Add-in wraps Telephony Application Programming Interface TAPI Calls in a public method Dial Phone. A similar...
Controls Collection Object Properties
The Controls collection object provides only the Count property. With the Count property, you can use the For Next statement to loop through the controls in a collection. The following example returns the collection of controls on the Controls collection object page. It then displays the name of each control contained on the page. Sub ShowtheControlsCollectionCount_Click Set Page Object Set MyControls Page.Controls For i 0 to MyControls.Count -1 MsgBox MyControls i .Name, vblnformation Next End...
ItemRemove
The ItemRemove event occurs when an item is removed from a specified Items collection object, either through user action or programmatically. The following example expands on the FolderRemove example described earlier to show how to undelete an item programmatically. This example undeletes a custom form with a message class of IPM.Post.ContactSettings if a user deletes the item from the Settings subfolder of the Inbox. 'Place these declarations in the general section of ThisOutlookSession...
Writing Code to Respond to Events
Outlook macros are very useful for simple repetitive tasks. However, macros are only a snack compared with the banquet of events available in the Outlook 2002 Object Model. For Visual Basic developers, the key to writing code that responds to events is learning how to use the WithEvents keyword in Visual Basic. Use the WithEvents Keyword to Declare Object Variables The WithEvents keyword is used to dimension an object variable in a class module. If you attempt to use WithEvents in conjunction...
Command Bar Caveats
There are a couple of issues you should be aware of when creating COM Add-ins that display custom command bars or command bar buttons. If you want your command bar button to display custom icons, you must explicitly set a reference to the Microsoft Office 10.0 Object Library. The Office XP CommandBarButton object supports a Picture and a Mask property that letyou use custom images for your command bar buttons. If you need your COM Add-in to run in both Outlook 2000 and 2002, you must set the...
Copy the Folder to Public Folders 1
Now you've created forms and a custom view for the Product Ideas folder. You've also tested the folder to make sure it works as planned. Now copy the folder from the Design Environment personal folder to public folders so that the folder can be shared by a workgroup or across the entire organization. Before you copy the folder, you might want to discuss with your administrator the best location for the folder. In addition, you might need to get the appropriate permissions to copy the folder to...
Copy the Folder to Public Folders Tdn
After adding forms, defining views, and testing their functionality, you are ready to copy your folder to Public Folders. You can then complete the folder design by designating typesof items allowed in the folder, setting permissions, setting administration properties, and specifying rules. This step is necessary only if you started the folder design process with a personal folder or a mailbox folder, and not with a public folder. Depending on the policies of your organization, you might not...
J Uyt
Figure 3.6 - The Company column is placed in front of the Full Name column Add the Column Headings to the Column Heading Row To add column headings, you drag the fields you created earlier from the Field Chooser to the Column Heading row. To drag the fields to the Column Heading row 1. From the Field Set drop-down list box on the Field Chooser, select User-Defined Fields In Folder. 2. Drag the Comments Or Issues field from the Field Chooser to the Column Heading row, and position It to the...
The UserProperties Collection Object
The UserProperties collection object represents the custom fields contained in an item. To return a collection of user-defined fields for an item, you can use the UserProperties property of the Mailltem object, the Postltem object, and so on. The UserProperty object represents a single field in the item. For a complete list and description of the properties and methods for the UserProperties collection object, see Microsoft Outlook Visual Basic Reference Help. Standard properties in Outlook,...
Specify the Default Form for the Folder
Now that you've created a custom form, you may want to run it to see if it works as expected. However, at this point, there are two possible forms that you can open. One form is the built-in Contacts form that's provided with Outlook. The other is the Beta Contact form you created. If you click the New Contact button on the Standard toolbar, the built-in Contacts form appears. You must click New Beta Contact on the Outlook Actions menu to open the Beta Contact form you created. To avoid this...
The Application Object
The Application object sits at the top of the object model and represents the entire Outlook application. The Outlook Application object has several purposes As the root object, it enables you to reference other objects in the Outlook object hierarchy. It provides methods such as Createltem and CreateObject so that you can create new items and reference them without moving through the object hierarchy. It provides methods for directly referencing the active Outlook window or form. For a...
The Forms Cache
The forms cache is a local file system folder that serves as a forms storage location. The forms cache improves the load time of a form because commonly used forms are loaded from the hard disk rather than downloaded from Microsoft Exchange Server. When a form is activated for the first time, the form definition file is copied from its forms library to the user's Forms folder. The forms cache keeps a temporary copy of the form definition in a subfolder whose name roughly matches the name of the...
Activate
The Activate event occurs when an Explorer window becomes the active window. Be careful not to overload this event procedure with code because the Activate and Deactivate events fire many times during an Outlook session. Each time a user opens an Inspector for an item, the following event sequence occurs The following code example shows you how to use the Activate event to make a command bar named Contacts visible or invisible, depending on the current folder in the Explorer
Info Lip
jJ Country Region Brazil 9 items ip Product I File Edit View Insert Format Tools Actions Form Layout Help i . SFA Q Save and Close R Kj V 0 T T - jji Shared Mail Shared Appointment vj Shared Task jjJ Shared Contact Shared Journal P Shared Document General Notes Shared Activities Show shared Journal View Entry List by Created On jd Created On Tuesday, February 27, 2001 12 00 AM 1 item, 1 unread
Explorer Events
Explorer events provide you with a great deal of control over the Outlook user interface. You can now control the size and window state of Explorer windows, respond to selection changes through the new SelectionChange event and the Selection object, and determine when the user has changed her view or the current folder. Outlook 2002 adds a group of events that provide a granular level of control over the Outlook application window. These events are BeforeMaximize, BeforeMinimize, BeforeMove,...
J Hen
This procedure create an Access table linked to the Outiook Contact folder, Access, Excel, or Word 2000 or Greater Microsoft Outlook9,0 Object Library or higher Reference checked Function LinkEHchangeE'oider strTabieName As Boolean This procedure creates an Access tahle linked to the Outlook Contf ts folder l' l in dbsDatabase As DAO.Database Dim tdfTable As DAO TableDef Dim strConnect As String 1 Set a reference to the current database. Set dbsDatabase CurrentDb strConnect Exchange 4...
ItemAdd
The ItemAdd event occurs when an item is added to an Items collection object, either through user action or program code. The following example creates an Items collection object for an Exchange public folder named Customers that contains Contact items. When a new customer is added to the Customers folder, a message is sent to a distribution list for the correct regional sales team. This example requires another event procedure in order to instantiate the collection object for the Customers...
The PropertyChange Event
The PropertyChange event occurs when one of the item's standard fields such as Subject, To, Importance, or Sensitivity changes. Because the field name is passed to the procedure, you can use the Select Case statement to determine which field value has changed. In the following example, a message box shows the values of the Importance and Sensitivity fields that have changed. To see how it works, add the following code to the Script Editor. Then exit Design mode and change the values in the...
AddressEntry Object Methods
This section covers the Details, Update, Delete, and GetFreeBusy methods of the AddressEntry object. Displaying Details of an Address Entry The Details method of the AddressEntry object displays a modal dialog box that lets a user see and, if permissions allow, change the information stored in the Address Book item represented by the object. The following example steps through the items in a user's Personal Address Book, using the Details method to display the information contained in each...
End Sub AddressEntry Properties
You can use such properties as Name, Address, Members, Type, and Manager to retrieve useful information contained in the item. For a complete list and description of the methods and properties for the AddressEntry object, see Microsoft Outlook Visual Basic Reference Help. The following example uses the Members, Name, and Address properties of the AddressEntry object to display the name and address of each member of a private distribution list named Department Sub Displayl_istMembers_Click On...
Inspector Object Methods
This section covers the SetCurrentFormPage, HideFormPage, and ShowFormPage methods of the Inspector object. Setting the Current Form Page You can use the SetCurrentFormPage method of the Inspector object to set the current form page of a form. The following example shows the Details page as the current form page of a Contact form when you click CommandButtonl. To use this example, you must add a command button to a Contact form in Design mode. Add the code in the Script Editor, and then run the...
Distribute Forms
This section provides information, strategies, and instructions for distributing forms in your organization. It covers how to Make forms available in the Organizational Forms Library, the Personal Forms Library, or a Folder Forms Library. Change the standard IPM.Note message. Send a form to an administrator or to another user. Distribute forms in a personal folder .pst file. Make forms available for offline use. Make Forms Available in the Organizational Forms Library Most often, the types of...
strScope strFilter blnSearchSubfolders strTag End Sub
The Test Trust COM Add-in is a simple example of how to handle the issues that you must confront when your Add-in calls blocked methods and properties in the Outlook 2002 Object Model. Test Trust creates a toolbar button that displays a dialog box that you use to send a message to yourself. If you include this Add-in on the list of trusted COM Add-ins in the Administrative form located in the Outlook Security Settings public folder, you can observe how the trust mechanism suppresses the Object...
The CommandBars Collection Object
The ability to program the Outlook Bar gives you a significant level of control over the Outlook user interface. Using the OutlookBarGroups and OutlookBarShortcuts events, you can prevent a user from removing an Outlook Bar group or shortcut that is essential to your application. You can also dynamically add Outlook Bar groups and shortcuts. You don't have the same flexibility, however, with Outlook Bar objects as you do with all the objects belonging to Office command bars. CommandBar and...
I Eyy
iP-M P, 6 All Fields Properties Actions rhe Total Days control is bound to the 1 Total Days field It shows the result of the values in the StartDate and End Date fields. Figure 6.17 - Label controls on the Vacation Request form. When to Bind a Label Control Generally, you bind Label controls to fields when you want to save the value to the item. For example, in the Vacation Request form, as shown in Figure 6-17, the Total Days label is bound to the TotalDays field. In this way, the value in the...
J Lxk
The View drop-down list allows the user to select Views for the folder select in the Show drop-down lis Figure 12.3 - The Shared Activities page uses the Outlook View Control to display information in shared folders. Figure 12.3 - The Shared Activities page uses the Outlook View Control to display information in shared folders. The Northwind Contact Management application also makes use of the PivotTable List ActiveX control in Microsoft Office XP. An Office XP Web Component, the PivotTable...
The Label BackStyle property is set to Transparent in the Advanced Properties
Figure 6.3 - The BackStyle property of the Labelz control is set to Transparent, so the control appears to be part of the Image 1 control behind it. of available fields in the field list in the Properties dialog box, as shown in Figure 6-4. To bind a control to an existing field 1. Right-click the control you want to define a field for, and then click Properties on the shortcut menu. 3. Click Choose Field, point to the set of fields you want, and then click the field. The sets of fields...
Outlook Security
Perhaps the most significant new feature of Outlook 2002 is the Outlook E-Mail Security Update. Introduced in response to the damage wrought by e-mail viruses such as Melissa and ILoveYou, the Outlook E-Mail Security Update was offered originally as a patch for Outlook 2000 SR-1 a and Outlook 98. This update is not available for Outlook 97. In Outlook 2000 SP2 and Outlook 2002, the Outlook E-Mail Security Update is built into Outlook. It cannot be removed, and administrative control is...
L The item is posted in the folder and grouped according to selections on the
Figure 8.14 - The Classified Ad form. If your application makes use of custom forms, you should consider enforcement of validation rules to ensure that views are complete and logical for the user. A validation rule on a user-defined field requires that a given field have a value, or one value from a range of possible values. To group items by using Customize Current View 1. On the View menu, select Current View, click Customize Current View, and then click Group By. 2. In the Select Available...
Info Tgc
Figure 8.16 - Items in each group are sorted alphabetically by Subject in the Item Of Interest column. To sort items 1. On the View menu, click Current View, and then click Customize Current View. 3. In the Select Available Fields From drop-down list box, click the category of fields containing the field you want to use for sorting. 4. Under Sort Items By, click the field you want to use to sort items by. 5. Click either Ascending or Descending to choose the sort order. 6. To sort items into...
Select
lt table border 0 cellpadding 0 cellspacing 0 style width 100 gt lt tr gt lt td width 30 align left gt lt SELECT id cmbView_WPQ_ class select style display none lt OPTION lt td colspan 2 width 20 gt lt td gt lt td width 10 align left valign center gt lt span id AdvFindltem_WPQ_ class SPAN_WPQ_normal amp nbsp amp nbsp Find lt span gt lt td gt lt td width 10 align left valign center gt lt span id Newltem_WPQ_ class SPAN_WPQ_normal amp nbsp amp nbsp New lt span gt lt td gt lt td width 10 align...
Only items created wit the Classified Ad form show in the folder
Figure 8.21 - The filter for the By Ad Type view shows only items created with the Classified Ad form I PM. Post. Create Ad in the folder. Filters consist of a condition or set of conditions that determine what items are shown in a folder. For example, a condition could be From Jim Hance. Conditions can have multiple arguments. For example, From Jim Hance Don Funk. Here are a few simple guidelines to follow when creating conditions Multiple conditions are logical AND values For example, the...
Sa M s
Controls selected in the Additional Controls dialog box will be added to your Outlook toolbox, Microsoft Chart Control, version 6.G OLEDB Microsoft Communications Control, version K'itj Microsoft Coolbar Contrai, version .D Li Microsoft DataCornbo Control, version S. OLhD Microsoft DataGrici Control, Version 6. I OLEDB Microsoft DataList Control, version E.O OLEDB Microsott DataRepeaier Control, version .0 3 Microsoft Date and Time Picker Control, version E Microsoft DBCombo Control, version...
















