更新用户配置文件,使其指向新的 Exchange 服务器

更改用户配置文件,包括.prf 文件,以反映新的邮件服务器。每个用户基于注册表的设置执行只有一次。
Visual Basic
Set oShell = CreateObject(“WScript.Shell”)

sRegKey = “HKCU\Identities”

‘ suppress error in case values does not exist
On Error Resume Next

‘ check for marker
sNewProfile = oShell.RegRead( sRegKey & “\NewProfile”)

If sNewProfile “yes” Then
‘ Run Outlook.prf
sCmd = “\\DC\netlogon\Outlook.prf”
oShell.Run sCmd, 1, True

‘ create marker
oShell.RegWrite sRegKey & “\NewProfile”, “yes”

End If

Latest posts by Exchange中文站 (see all)
发布于: 浏览:1262 次

还没有评论

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据