Become a Columnist Microsoft Exchange Site Microsoft Support SiteMSDN Exchange Site

   

Subscribe to OutlookExchange
Anderson Patricio
Ann Mc Donough
Bob Spurzem
Brian Veal
Catherine Creary
Cherry Beado
Colin Janssen
Collins Timothy Mutesaria
Drew Nicholson
Fred Volking
Glen Scales
Goran Husman
Guy Thomas
Henrik Walther
Jason Sherry
Jayme Bowers
John Young
Joyce Tang
Justin Braun
Konstantin Zheludev
Kristina Waters
Kuang Zhang
Mahmoud Magdy
Martin Tuip
Michael Dong
Michele Deo
Mitch Tulloch
Nicolas Blank
Pavel Nagaev
Ragnar Harper
Ricardo Silva
Richard Wakeman
Russ Iuliano
Santhosh Hanumanthappa
Steve Bryant
Steve Craig
Todd Walker
Tracey J. Rosenblath
 
 

Automating the Installation of Outlook Forms for off-line users

My client has 200 or so remote off-line users who use Outlook to connect to their corporate Exchange server for mail. The PCs only connect long enough to retrieve and send mail, then they disconnect. I created several custom forms (many are reply only forms). I had to get the forms installed on the remote PCs in the personal forms registry without travelling to several states. I tried creating Favorites folders and synchronizing, then have the users copy the forms to the Personal Forms registry. I tried sending the Outlook templates and having the users publish the forms. These methods took too much time. Especially when many of the users have never used a computer before. I had to come up with a fully automated solution.

Here it is:

First: I send an email to a remote user that has an InstallShield self-extracting file attached. When double-clicked, the InstallShield self-extracting file "dumps" all of the Outlook Templates (.OFT), MS Word templates, Access databases, and a Visual Basic program into the directory "C:\common\Formsdata\" . (including the necessary files to run the VB program in the Windows system directory) (the Word templates and Access databases are used by the Outlook forms)Second: the InstallShield self-extracting file runs the Visual Basic program.The VB program looks for all .OFT files in the c:\common\formsdata directory and publishes each one in the Personal forms registry.

This is the VB Program:

Sub main()
Dim filename As String
Dim Temp As String
Dim endpos As Integer
Dim mylength As Integer
Set myOlApp = GetObject("", "Outlook.Application")
' retrieve Outlook Templates
filename = Dir$("c:\common\formsdata\*.oft", vbNormal)
Do Until filename = ""
mylength = Len(filename)
' strip off the extension from the filename. This will be the
name of the form.
endpos = InStr(1, filename, ".oft", 1)
strTemp = Trim(Mid(filename, 1, endpos - 1))
' publish all Outlook forms into the Personal Registry
Set myItem =
myOlApp.createitemfromtemplate("C:\common\formsdata\" & filename)
Set myform = myItem.formdescription
myform.Name = strTemp
myform.PublishForm olPersonalRegistry
filename = Dir$
Loop
End Sub

After the user receives the e-mail, all they have to do is double-click on the attachment and everything is installed.

MARK G. WISNIEWSKI
615-356-2686 Extension 16
mark.wisniewski@worldnet.att.net


Disclaimer: Your use of the information contained in these pages is at your sole risk. All information on these pages is provided "as is", without any warranty, whether express or implied, of its accuracy, completeness, fitness for a particular purpose, title or non-infringement, and none of the third-party products or information mentioned in the work are authored, recommended, supported or guaranteed by Stephen Bryant or Pro Exchange. OutlookExchange.Com, Stephen Bryant and Pro Exchange shall not be liable for any damages you may sustain by using this information, whether direct, indirect, special, incidental or consequential, even if it has been advised of the possibility of such damages.

Copyright Stephen Bryant 2008