Using a SQL data connection to find a user's email in Active Directory - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Using a SQL data connection to find a user's email in Active Directory

Last post 02-20-2013 12:59 PM by Parrrott. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 02-20-2013 08:50 AM

    Using a SQL data connection to find a user's email in Active Directory

    Here is my scenario: I have created a Timesheet form in Infopath 2010 that has a receive data connection to a SQL database, which I set up through DBXL. The SQL table my form is connected to contains a hierarchy for my company. In the form, I have a dropdown box that lists all of the Employee ID Numbers in the SQL table and when a user selects their ID Number, their supervisor's name is automatically assigned to a hidden "Supervisor" field in the form. All of this works perfectly thanks to DBXL. My plan was to use the "Supervisor" field to query Active Directory in order to receive that supervisor's email address, so that an email would be sent to the appropriate supervisor when a user submits a Timesheet form. I was trying to use the FindUsersByName operation to accomplish this, but this will not return a result when I use the supervisor's name I received from SQL to query Active Directory. I'm assuming this is because the name is in a SQL data type instead of plain text, as the FindUsersByName query does work if I type a name into the search instead of using the "Supervisor" field. Does anyone know of a way to make this work? Thanks in advance for any assistance.
  • 02-20-2013 10:52 AM In reply to

    Re: Using a SQL data connection to find a user's email in Active Directory

    Hi,

    What you're describing should work. Since you have a scenario set up and a form, perhaps it would be best to send us email via support at qdabra dot com and include the form so that we can take a look at your implementation and identify any potential issues.

    Thanks.

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 02-20-2013 12:59 PM In reply to

    Re: Using a SQL data connection to find a user's email in Active Directory

    Thanks for the quick response Ernesto. I actually found that some of the fields in the SQL table had extra spaces at the end of the names for some reason, which is why the FindUsersByName query wasn't working. I used the translate() function to delete those unnecessary spaces and everything now works as intended. Thanks again for the response.
Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.