Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am using a powershell script to make some exporting from various Exchange mailboxes. The main point consists of creating a profile for each affected mailbox and invoke outlook.exe /importPRF customprofile.prf and so on. The main logic and everything works fine, but one problem occurs: If usernames are prefixes of one another (say I have "Foo" and "Foobar") then the profile for the shorter ("Foo") interrupts the automated script and instead a dialog window pops up whether I want to have "Foo" or "Foobar". The name enters into the profile file customprofile.prf in form of MailboxName lines

[Service List]
ServiceEGS1=Exchange Global Section
Service1=Microsoft Exchange Server
...
[ServiceEGS1]
MailboxName=Foo
...
[Service1]
MailboxName=Foo
...

What can be done so that no Foo vs. Foobar question pops up? In other words: It seems that "Foo" is really interpreted as something like a regex "/Foo.*/". How to make "Foo" really stand for "/^Foo$/" (though of course no regexes can be entered there)

(In case it is important: the usernames are the SamAccountName taken from Active Directory)

share|improve this question

1 Answer 1

up vote 2 down vote accepted
+50

I know it looks weird, but in order to avoid the ANR (automatic Name Recognition) you have to prefix the mailboxname with an equals sign =

For example

MailboxName==Foo
share|improve this answer
    
Excellent! Works like a charm. –  Hagen von Eitzen Jan 8 '13 at 8:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.