Apoc70/MailboxCategoryListManager

Org-wide Import of Categories

GCHPX opened this issue · 2 comments

GCHPX commented

Hi there,

thank you for the tool, i was just wondering if it is possible to to Import the Categories Org-wide for all the Users.

Thank you and cheers
gc

Hello gc,

you can script this because the program take also parameters for import and export. Something like that could do the trick:
For more parameters start the program with the "-help" parameter.

# Filter here for more, like user names or organizational units
$Mailboxes = get-mailbox -Filter {RecipientTypeDetails -eq "UserMailbox"}
Foreach ($Mailbox in $Mailboxes)
{
 	# Depending on the number of mailboxes you maybe want to do a Start-Sleep
	Start-Process -FilePath .\CategoryManager.exe -ArgumentList "-Mailbox $($Mailbox.PrimarySMTPAddress) -import D:\CategoryManager\export.xml -user ""admin@contoso.de"" -password ""Pa$$w0rd"" -impersonate" -Wait -NoNewWindow
}
GCHPX commented

Hey @xedoc64, Thank you very much for your answer and sorry for not getting back to you earlier...crazy times :/

I just checked the script but it doesn't seem to work. I tried to execute only the Command as follows :

.\CategoryManager.exe -mailbox "user@domain.com" -import .\categories.xml -allowredirection -user "admin@contoso.com" -password "Pa$$w0rd" -impersonate -cleareimport

And i get the same error, with the script and the only the command: Error on creating the service. Check permissions and if the server is avaiable.

Do you have any idea where this comes from? The Credentials are working if i push it over the GUI Application.

Thank you and best wishes!
GC