I'm trying to create a UPS sync connection using powershell. Becuase of the vagaries of our AD setup I can't use the Central Admin 'Create New Connection' function.
I am using the script below which is copied directly from the technet article on the AddSPProfileSyncConnection command and modified with our deployments data.
Add-SPProfileSyncConnection -ProfileServiceApplication 3b0a7b01-d954-4120-90b5-caa9382ebd9a -ConnectionDomain MyNETBIOS -ConnectionForestName My.Forest.Name -ConnectionPassword convertto-securestring "Password" -asplaintext -force -ConnectionSynchronizationOU TopOU -ConnectionUserName Domain\svc_spdev_pfl -ConnectionPort 389
When I run the script I get an error message:
Cannot bind parameter 'ConnectionPassword' Cannot convert the "convertto-securestring" value of type "System.String" to type "System.Security.SecureString".
What have I done wrong?