Solved

Using Managed Code in InfoPath 2007

Posted on 2008-10-24
2
963 Views
Last Modified: 2013-12-14
I have a fully trusted browser-based InfoPath 2007 form with C# code on the loading event to pull user information from Active Directory which I then populates some form fields.  If I preview the form on my local machine everything works fine.  When I upload to the server as an admin in Central Admin, the fields no longer populate for any user loading the form.  Any ideas on what I may be missing?

Also,  have a separate form loading event logic to set default values that works fine.  I have the form pointed to a shared folder on the server with the actual code.
0
Comment
Question by:bkv1997
2 Comments
 
LVL 28

Accepted Solution

by:
clayfox earned 500 total points
ID: 22797624
I would recommend using a web service to get AD info, then you do not have to hassle with code and full-trust. qdabra.com has one prebuilt as an example.

You would need to give the account that is runing the code in IPFS permision to query AD. The user credentials would not be used but the hosting server's.
0
 

Author Comment

by:bkv1997
ID: 22833864
It was a permissions issue.  I supplied the account name and password as a parameter to the DirectoryEntry constructor, and that took care of it.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Programmer's Notepad is, one of the best free text editing tools available, simply because the developers appear to have second-guessed every weird problem or issue a programmer is likely to run into. One of these problems is selecting and deleti…
Before you can digitally sign infopath forms, you must have a digital certificate. Microsoft Certificate Services will need to be enabled on a Windows Server 2008 to facilitate the creation and verification of the digital certifciates on the web ser…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question