CFEXCHANGECONNECTION error when username changes.

Posted by Tom Hubbard on Stack Overflow See other posts from Stack Overflow or by Tom Hubbard
Published on 2010-03-08T19:06:05Z Indexed on 2010/03/08 19:21 UTC
Read the original article Hit count: 218

Filed under:

We are attempting to connect to an Exchange server through CFEXCHANGECONNECTION on ColdFusion 9 to retrieve email.

We can connect with a number of users. However, some users cannot connect. We end up with the following error:

Cannot access Exchange server as a web application at <server>

It turns out that the users who cannot connect either have a ampersand in there username or they have changed there username with CFLDAP.

So, if I perform a CFLDAP on a working user and change the userPrincipalName and sAMAccountName the user will begin getting the error above.

If I change it back to what it was to start with, the error will go away.

Any ideas?

EDIT

The ampersand part seems to be misleading. Essentially we found the problem because of the ampersand. However, for working users who did not have an ampersand, the error will begins showing up if their username is changed to something that does not have an ampersand.

© Stack Overflow or respective owner

Related posts about coldfusion