Quantcast
Viewing latest article 6
Browse Latest Browse All 16

Another Exchange custom remote issue

So, I just discovered another issue with my method of invoking a simple remote session to Exchange 2010.

The return types in many cases are deserialized so the following happens:

PS> (get-mailbox dbailey) -is "Microsoft.Exchange.Data.Directory.Management.
Mailbox"
Unable to find type [Microsoft.Exchange.Data.Directory.Management.Mailbox]: 
make sure that the assembly containing this type is loaded.

PS> (get-mailbox dbailey) | gm


   TypeName: Deserialized.Microsoft.Exchange.Data.Directory.Management.
Mailbox

PS> (get-mailbox dbailey) -is "Deserialized.Microsoft.Exchange.Data.
Directory.Management.Mailbox"
Cannot convert the "Deserialized.Microsoft.Exchange.Data.
Directory.Management.Mailbox" value of type "System.String" 
to type "System.Type".

Doh! Again, that pesky startup code appears to be there for a reason. It’s not just adding the tip of the day and mucking with your colors and title bar.


Viewing latest article 6
Browse Latest Browse All 16

Trending Articles