• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Need help with a vb script that add the reply to all button in outlook 2003.

VenomXt

Blame me for the RAZR's
#1
Ok here is what’s going on. We run a vb scrip to remove the reply to all button in outlook 2003. It auto runs during the install of outlook 2003. A few people would like the button back (and are allowed to have it)

They know the short cut key (ctrl-shift-r) and still want the button.

My VB is very rusty and I was hoping someone here would look at this and it would instantly come to them.

Here is the remove code.


Option Explicit
' ===================================================================
' Title: Removes the Reply to all button from Outlook 2003
'
'
'
' Description:
'
' This program is designed to remove the reply to all functionality from
' the outlook 2003 client
'
' This file should be located in the Outl11 installation area
'
' Dependancies:
'
'
' --------------------------------------------------------------------
' Revision History
' --------------------------------------------------------------------
' Date Who Description of changes
' ---- --- ------------------------------------------
'
' 11/3/05 ABJ Initial Creation
'
'
' Begin Script
' Define variables for operation
Dim WshShell, WshProcEnv, SSO, retval, SSOSet, WINVer, strComputer, oReg, strKeyPath, strValueName, strValue, objOperatingSystem
Dim strKeyPath1, strValueName1, strValue1, strKeyPath2, strValueName2, strValue2, objWMIService, colOperatingSystems, strValue3, strValueName3, strKeyPath3, strKeyPath4, strValueName4, strValue4
' Set operational variables
Const HKEY_CURRENT_USER = &H80000001
strComputer = "."
Set objWMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colOperatingSystems = objWMIService.ExecQuery ("Select * from Win32_OperatingSystem")
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
Set WshShell = WScript.CreateObject("WScript.Shell")
Set WshProcEnv = WshShell.Environment("Process")
SSOSet = False
strKeyPath = "Software\Microsoft\Exchange"
strKeyPath1 = "Software\Microsoft\Office\11.0\Outlook\Cached Mode"
strKeyPath2 = "Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles\GE E2K\13dbb0c8aa05101a9bb000aa002fc45a"
strKeyPath3 = "Software\Microsoft\Windows\CurrentVersion\Group Policy Objects\{69770FBC-071F-4CEE-8086-561332A59FA3}User\Software\Policies\Microsoft\Office\11.0\Outlook\DisabledCmdBarItemsList"
strKeyPath4 = "Software\Policies\Microsoft\Office\11.0\Outlook\DisabledCmdBarItemsList"
strValueName = "LogonDomain"
strValueName1 = "DownloadOAB"
strValueName3 = "UserName"
strValueName2 = "001e6607"
strValueName4 = "TCID1"
strValue = "E2k\" & SSO
strValue1 = "00000000"
strValue2 = SSO
strValue3 = "e2k.ad.ge.com"
strValue4 = "355"
'Disables the reply to all button within Outlook 2003
oReg.CreateKey HKEY_CURRENT_USER,strKeyPath3
oReg.CreateKey HKEY_CURRENT_USER,strKeyPath4
oReg.SetStringValue HKEY_CURRENT_USER,strKeyPath3,strValueName4,strValue4
oReg.SetStringValue HKEY_CURRENT_USER,strKeyPath4,strValueName4,strValue4

'Writes registry values that create cache mode and download OAB disable
oReg.CreateKey HKEY_CURRENT_USER,strKeyPath1
oReg.SetDWORDValue HKEY_CURRENT_USER,strKeyPath1,strValueName1,strValue1
' Set the exchange profile userid to user's SSO
oReg.SetStringValue HKEY_CURRENT_USER,strKeyPath2,strValueName2,strValue2
Big reps coming if you can help.
 

fitz

Woah.. I'm still here?
Staff member
Political User
#6
do you need this as a VBScript? Why not just remove the regkeys created by the script?

edit:
here.. just modified your script. Haven't tested it.. just hacked the original script to remove the values set by the original script.

I'm home sick.. otherwise I would have tested it prior to posting it.

Code:
                             Option Explicit
' ===================================================================
' Title: Removes the Reply to all button from Outlook 2003
' 
' 
' 
' Description:
' 
' This program is designed to replace the reply to all functionality from
' the outlook 2003 client
'
' Dependancies:
' 
'
' --------------------------------------------------------------------
' Revision History
' --------------------------------------------------------------------
' Date Who Description of changes
' ---- --- ------------------------------------------
'
' 11/3/05 ABJ Initial Creation 
' 10/20/06 Fitz! Woo! -- Made to readd the reply to all function
'
' Begin Script
' Define variables for operation
Dim WshShell, WshProcEnv, SSO, retval, SSOSet, WINVer, strComputer, oReg, strKeyPath, strValueName, strValue, objOperatingSystem
Dim strKeyPath1, strValueName1, strValue1, strKeyPath2, strValueName2, strValue2, objWMIService, colOperatingSystems, strValue3, strValueName3, strKeyPath3, strKeyPath4, strValueName4, strValue4
' Set operational variables
Const HKEY_CURRENT_USER = &H80000001
strComputer = "."
Set objWMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colOperatingSystems = objWMIService.ExecQuery ("Select * from Win32_OperatingSystem")
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
Set WshShell = WScript.CreateObject("WScript.Shell")
Set WshProcEnv = WshShell.Environment("Process")
SSOSet = False
strKeyPath3 = "Software\Microsoft\Windows\CurrentVersion\Group Policy Objects\{69770FBC-071F-4CEE-8086-561332A59FA3}User\Software\Policies\Microsoft\Office\11.0\Outlook\DisabledCmdBarItemsList"
strKeyPath4 = "Software\Policies\Microsoft\Office\11.0\Outlook\DisabledCmdBarItemsList"
strValueName4 = "TCID1"
strValue4 = "-"
'ReEnables the reply to all button within Outlook 2003
oReg.SetStringValue HKEY_CURRENT_USER,strKeyPath3,strValueName4,strValue4
oReg.SetStringValue HKEY_CURRENT_USER,strKeyPath4,strValueName4,strValue4
 
Last edited:

Members online

No members online now.

Latest posts

Latest profile posts

Hello, is there anybody in there? Just nod if you can hear me ...
Xie
What a long strange trip it's been. =)

Forum statistics

Threads
61,961
Messages
673,239
Members
89,014
Latest member
sanoravies