Link to home
Start Free TrialLog in
Avatar of bsharath
bsharathFlag for India

asked on

Any script that can configure the Outlook with the logged in name

Hi,

Any script that can configure the Outlook with the logged in name.And at the end prompt for a pst location.

Any this can be done with a script.
Office 2003
Win Xp
Win 2003

Regards
Sharath

Avatar of chandru_sol
chandru_sol
Flag of India image

Hi Sharath,

Use this link to create the outlook profile

http://www.outlook-tips.net/howto/prf.htm

Script below can be use to create the profile only once
'Scripts starts here
Option Explicit
On Error Resume Next


' Dim Our Variables
Dim objShell, objOutlook
Dim sFRKey, sFRSearch, sOutlookVersion

' Create Outlook object and Shell object

set objOutlook = CreateObject("Outlook.Application")
set objShell = CreateObject("WScript.Shell")

' Determine Which version client is using before moving on

if objOutlook.Version >= "11.0" And objOutlook.version <= "11.1" Then
sOutlookVersion = "11.0"
End If

if objOutlook.Version >= "10.0" And objOutlook.version <= "10.1" Then
sOutlookVersion = "10.0"
End If

if objOutlook.Version >= "9.0" And objOutlook.version <= "9.1" Then
sOutlookVersion = "9.0"
End If

if objOutlook.Version >= "8.0" And objOutlook.version <= "8.1" Then
sOutlookVersion = "8.0"
End If

'Strings
sFRKey = "HKEY_CURRENT_USER\Software\Microsoft\Office\"
sOutlookVersion & "\Outlook\Setup\First-Run"
'Search for it
sFRSearch = objShell.RegRead(sFRKey)


' Does key exist?
If err <> 0 Then
'Wscript.Echo "PRF is being Imported"
objShell.RegWrite "HKEY_CURRENT_USER\Software\Microsoft\Office\"
sOutlookVersion & "\Outlook\Setup\ImportPRF", "\\DCserver1\NETLOGON
\Outlook\Outlook.prf", "REG_SZ"
objShell.RegDelete "HKEY_CURRENT_USER\Software\Microsoft\Office\"
sOutlookVersion & "\Outlook\Setup\First-Run"
objShell.RegDelete "HKEY_CURRENT_USER\Software\Microsoft\Office\"
sOutlookVersion & "\Outlook\Setup\FirstRun"
Else
'Wscript.Echo "PRF exists"
End if


' Clean up
set objShell = Nothing
set objOutlook = Nothing

Hope this helps.......
Avatar of bsharath

ASKER

Chandru is this a Vbs file and should i change anything  in the script..
You need to have a prf file in the shared location and then save the code as a vbs script
Chandru i just went through the microsoft site regarding Prf. Can you help creating one and do you have any already made...
I think there is an example one which you can download and modify. Let me have a look and see what are the parameters required.
Ok Chandru
Did you try this?
I checked but no improvement.Can you help...
Can you let me know what you tried?
Chandru i followed this page.

http://www.outlook-tips.net/howto/prf.htm

What i dont understand is
What can this help...
Create a file then?
All my settings will be stored how can i user this to setup a different profile.
Chandru i used this
Custom Installation Wizard
And created the Mst file now how do i run it...
New Custom Setup File.MST
Hi Got it.

I created a Mst file and when i use this

\\machinename\foldername\setup.exe TRANSFORMS="\\indiasophos\c$\New Custom Setup File.MST" /qb-

I am able to get the profile autoconfigured.
When i login to the machine i get outlook configured but how do i run just the mst file as Office is already installed in these machines and i just need to configure them.
What does the ablove script do?
How can i use a UNC path

\\Machinename\foldename\setup.exe TRANSFORMS="Machinename\foldenam"\New Custom Setup File.MST" /qb-


I get an error.Cannot find the path.

Can we use a UNC path to fetch the MST file
ASKER CERTIFIED SOLUTION
Avatar of chandru_sol
chandru_sol
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I would prefer the above method as we do in our office, if not please try the link below

http://www.windowsitpro.com/Articles/ArticleID/93351/93351.html?Ad=1
Chandru thanks i shall look into this any update on the excel user creation
Still didn't start working on that. Hopefully tonight i will work on this as i have to setup exchange to test this