Re: I need to generate list of all SMTP address.
- From: "Lee Derbyshire [MVP]" <email a@t leederbyshire d.0.t c.0.m>
- Date: Wed, 21 Mar 2007 14:20:34 -0000
The line(s):
strDomainDN = InputBox("Please Enter the Servername and Domain DN. " &
vbCrLf & " Example: Myserver/DC=test,DC=lab ")
should all be one line - it looks like it is too long for most
newsreaders to display on one line. You can't end a line of script
with a & on its own. It should either be one line, or the first lines
should end with a continuation character _
strDomainDN = InputBox("Please Enter the Servername and Domain DN. " &
_
Lee.
--
_______________________________________
Outlook Web Access For PDA , OWA For WAP
www.owapda.com
email a@t leederbyshire d.0.t c.0.m
_______________________________________
"pez" <peter.zelonis@xxxxxxxxx> wrote in message
news:1174485251.648494.161830@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Mar 21, 9:25 am, "Jamestechman" <jamestech...@xxxxxxxxx> wrote:cscript
Save file below to exportemail.vbs, open command prompt, type
True)exportemail.vbs
Const Writable = 2
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objLog = objFSO.OpenTextFile("c:\proxydump.ldf", Writable,
" &Set cn = CreateObject("ADODB.Connection")
Set cm = CreateObject("ADODB.Command")
Set rs = CreateObject("ADODB.RecordSet")
With cn
.Provider = "ADsDSOObject"
.Open "Active Directory Provider"
End With
Set cm.ActiveConnection = cn
strDomainDN = InputBox("Please Enter the Servername and Domain DN.
of allvbCrLf & " Example: Myserver/DC=test,DC=lab ")
cm.CommandText = "
Set rs = cm.Execute
While Not rs.EOF
On Error Resume Next
strUserDN = rs.Fields("distinguishedName")
strMail = rs.Fields("mail")
strProxyAddress = rs.Fields("proxyAddresses")
objLog.Write "dn: " & strUserDN & vbCrLf
objLog.Write "changetype: modify" & vbCrLf
objLog.Write "replace: mail" & vbCrLf
objLog.Write "mail: " & strMail & vbCrLf
objLog.Write "-" & vbCrLf & vbCrLf
objLog.Write "dn: " & strUserDN & vbCrLf
objLog.Write "changetype: modify" & vbCrLf
objLog.Write "replace: proxyAddresses" & vbCrLf
For Each Item in strProxyAddress
strTempAddr = Item
objLog.Write "proxyAddresses: " & Item & vbCrLf
Next
objLog.Write "-" & vbCrLf & vbCrLf
rs.MoveNext
Wend
objLog.Close
msgbox "Export Complete to c:\proxydump.lfd"
James Chong (MVP)
MCSE | M+, S+, MCTS, Security+
msexchangetips.blogspot.com
On Mar 21, 9:12 am, "pez" <peter.zelo...@xxxxxxxxx> wrote:
I am fairly new to exchange environment. I need to get a list
to SPAMthe email addresses (including aliases) so I can give the list
can gofilter company. Is there an easy way to generate this list. I
anyinto ESM and export all the mailboxes, but this doesn't include
aliases. Any ideas? Thanks.
Thank you everyone who responded. In regards to JamesTech's script,
do I need to edit the script to include any specific information in
regards to my specific domain? I tried running the script and got a
syntax error, "exportmail.vbs(16,71) MS VBScript compilation error:
Syntax error. Sorry if this question is self-explanatory, I have no
vbscipt experience. Thanks
.
- Follow-Ups:
- Re: I need to generate list of all SMTP address.
- From: Lee Derbyshire [MVP]
- Re: I need to generate list of all SMTP address.
- References:
- I need to generate list of all SMTP address.
- From: pez
- Re: I need to generate list of all SMTP address.
- From: Jamestechman
- Re: I need to generate list of all SMTP address.
- From: pez
- I need to generate list of all SMTP address.
- Prev by Date: Re: Exchange Recipient Administrators cannot remove user
- Next by Date: Re: Out of Office Assisatnt Forwarding
- Previous by thread: Re: I need to generate list of all SMTP address.
- Next by thread: Re: I need to generate list of all SMTP address.
- Index(es):
Relevant Pages
|
Loading