Sorry for the late reply. Both those commands work with no errors.
[PS] C:\scripts\Ps>[System.DateTime]::Parse("15/01/2012")
15 January 2012 00:00:00
[PS] C:\scripts\Ps>$culture = new-object System.Globalization.CultureInfo(
"en-GB" )
[PS] C:\scripts\Ps>[System.DateTime]::Parse("15/01/2012", $culture)
15 January 2012 00:00:00
From: [email protected]
[mailto:[email protected]] On Behalf Of Michael
B. Smith
Sent: 30 January 2012 16:49
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
That surprises me. Forget the cmdlet for a minute and do the below straight
from the cmdline:
Does this fail?
[System.DateTime]::Parse("15/01/2012")
And then, does this fail?
$culture = new-object System.Globalization.CultureInfo( "en-GB"
)
[System.DateTime]::Parse("15/01/2012", $culture)
Thanks.
Regards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
From: Sobey, Richard A
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
Sent: Monday, January 30, 2012 11:30 AM
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Not quite, but what you are saying makes sense.
Get-MessageTrackingLog -Server ICEXCH-H1 -Sender
"[email protected]<mailto:[email protected]>" -Start
[DateTime]::Parse( "15/01/2012" )
Cannot process argument transformation on parameter 'Start'. Cannot convert
value "[DateTime]::Parse" to type "System.D
ateTime". Error: "String was not recognized as a valid DateTime."
+ CategoryInfo : InvalidData: (:) [Get-MessageTrackingLog],
ParameterBindin...mationException
+ FullyQualifiedErrorId :
ParameterArgumentTransformationError,Get-MessageTrackingLog
From:
[email protected]<mailto:[email protected]>
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
On Behalf Of Michael B. Smith
Sent: 30 January 2012 16:15
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Oh, you are gonna hate this one. That's not valid. You have to do it like this:
Get-MessageTrackingLog -Server ICEXCH-H1 -Sender
"[email protected]<mailto:[email protected]>" -Start
[DateTime]::Parse( "15/01/2012" )
It's a System.DateTime parameter, not a string parameter.
What's happening is you are getting caught up in the short-cut string
transformation.
Regards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
From: Sobey, Richard A
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
Sent: Monday, January 30, 2012 10:58 AM
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
E.G:
[PS] C:\scripts\Ps>Get-MessageTrackingLog -Server ICEXCH-H1 -Sender
"[email protected]<mailto:[email protected]>" -Start "15/01/2012"
Cannot process argument transformation on parameter 'Start'. Cannot convert
value "15/01/2012" to type "System.DateTime
". Error: "String was not recognized as a valid DateTime."
+ CategoryInfo : InvalidData: (:) [Get-MessageTrackingLog],
ParameterBindin...mationException
+ FullyQualifiedErrorId :
ParameterArgumentTransformationError,Get-MessageTrackingLog
[PS] C:\scripts\Ps>Get-MessageTrackingLog -Server ICEXCH-H1 -Sender
"[email protected]<mailto:[email protected]>" -Start "01/15/2012"
EventId Source Sender Recipients
MessageSubject
------- ------ ------ ----------
--------------
RECEIVE STORE... [email protected]<mailto:[email protected]>
{[email protected]<mailto:%[email protected]>...
RE: Outlook 2007 Sp2 Exchange ...
TRANSFER ROUTING [email protected]<mailto:[email protected]>
{[email protected]<mailto:%[email protected]>...
RE: Outlook 2007 Sp2 Exchange ...
SEND SMTP [email protected]<mailto:[email protected]>
{[email protected]<mailto:%[email protected]>...
RE: Outlook 2007 Sp2 Exchange ...
From:
[email protected]<mailto:[email protected]>
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
On Behalf Of Michael B. Smith
Sent: 30 January 2012 15:33
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
I've never heard of that and it sounds like a bug. Granted I'm en-us all the
way, so I don't see these types of problems.
Can you also run these for me? (Any PowerShell window, doesn't have to be EMS.)
(get-culture) | fl
(get-culture).DateTimeFormat
Thanks.
I need to figure out if PowerShell has the right values and it's an
Exchange-only issue, or a combo issue.
Regards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
From: Sobey, Richard A
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
Sent: Monday, January 30, 2012 10:18 AM
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Hah! Over here in Blighty I have to use "DD/MM/YYYY" for any date up to and
including the 12th of each month, and "MM/DD/YYYY" for the 13th and after. Or,
I can stick to "MM/DD/YYYY" throughout the entire command.
Grrr.
From:
[email protected]<mailto:[email protected]>
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
On Behalf Of Michael B. Smith
Sent: 30 January 2012 13:50
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Did you write dd/mm/yyyy ?? Really? Where are you?
Single vs. double quotes shouldn't make any difference.
Regards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
From: Joseph L. Casale
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
Sent: Monday, January 30, 2012 8:41 AM
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Right,
Unless I misunderstand it, Sent mail is mail you send whereas Received mail is
mail you received and I wanted both exported.
No errors are thrown, it accepts it but the job reports failed when viewing the
queue. I wasnt sure looking at the output of certain cmds versus their input as
to which format the date should have been specified in, MM/DD or DD/MM as a
Search-Mailbox being entered in one format returned results formatted in the
other?
The cmd that finally worked is DD/MM/YYYY in double quotes. Looking at my notes
it was second format I tried, but somewhere along the attempts I switched to
double quotes instead of single, who knows...
Thanks!
jlc
________________________________
From: Sobey, Richard A [[email protected]]
Sent: Monday, January 30, 2012 3:30 AM
To: MS-Exchange Admin Issues
Subject: RE: New-MailboxExportRequest issues
Your Sent and Received are the same? You may also need to specify a MM:HH in
addition to MM:DD:YYYY.
Can you send the output of the command when it fails?
From:
[email protected]<mailto:[email protected]>
[mailto:[email protected]]<mailto:[mailto:[email protected]]>
On Behalf Of Joseph L. Casale
Sent: 29 January 2012 04:10
To: MS-Exchange Admin Issues
Subject: New-MailboxExportRequest issues
Trying to export out sent and received items with a content filter of {(Sent
-lt '06/28/2011') -and (Received -lt '06/28/2011')}
This fails, whereas w/o the content filter, or with a simpler one it works.
Anyone see the issue?
Thanks,
jlc
Ps. Sorry for the lame sub, lyris's fault
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to
[email protected]<mailto:[email protected]>
with the body: unsubscribe exchangelist
---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to [email protected]
with the body: unsubscribe exchangelist