Link to home
Create AccountLog in
Avatar of C Emmons
C EmmonsFlag for United States of America

asked on

Help using new-mailboxsearch for Exchange Online

Trying to run commend such as,

New-MailboxSearch -Name "searchoperation" -SourceMailboxes username -TargetMailbox "discovery" -StartDate "01/01/2005" -EndDate "12/31/2006"

A positional parameter cannot be found that accepts argument '-targetmailbox'.
    + CategoryInfo          : InvalidArgument: (:) [New-MailboxSearch], ParameterBindingExcep
    + FullyQualifiedErrorId : PositionalParameterNotFound,New-MailboxSearch

Can someone please assist - I've found example on Internet -- but everything I try gives this general error.

Also, what I really want is to dump captured mail to PST file , not to a mailbox.  I've given myself Discovery permissions, and Full-Access to mailbox being searched.

Thanks in advance.
C Emmons
ASKER CERTIFIED SOLUTION
Avatar of Jason Crawford
Jason Crawford
Flag of United States of America image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer