Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista - Determine Mailbox under Storage Group in Exchange Server 2003

Reply
 
Old 09-04-2009   #1 (permalink)
Rahul


 
 

Determine Mailbox under Storage Group in Exchange Server 2003

Hi,

Please can you share any VBScript that can help determining number of
mailbox under exchange server or its storage group.

Thanks

My System SpecsSystem Spec
Old 09-05-2009   #2 (permalink)
Richard Mueller [MVP]


 
 

Re: Determine Mailbox under Storage Group in Exchange Server 2003


"Rahul" <rahulkohli2001@xxxxxx> wrote in message
news:fe19976e-d28d-4545-bb69-f68d29243ca0@xxxxxx
Quote:

> Hi,
>
> Please can you share any VBScript that can help determining number of
> mailbox under exchange server or its storage group.
>
> Thanks
I believe this should work:
=========
Option Explicit
Dim strComputer, objWMIService, objMailboxes

' Specify the Exchange Server.
strComputer = "ExchSrvr3"

Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate,authenticationLevel=Pkt}!\\" _
& strComputer & "\root\cimv2")

Set objMailboxes = objWMIService.ExecQuery _
("SELECT * FROM Exchange_Mailbox", , 48)

Wscript.Echo "Number of mailboxes: " & objMailboxes.Count

--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--


My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Exchange 2003 Mailbox Store defaults via VBScript VB Script
Exchange 2007 issue moving a Datbase mailbox to another storage group PowerShell
Set-mailbox like powershell cmdlets with the Exchange 2003 Server PowerShell
"unknow exception" when trying to create exchange 2003 mailbox. VB Script
How to create a mailbox in Exchange 2003 using Powershell PowerShell


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46