?
Solved

Using Managed Code in InfoPath 2007

Posted on 2008-10-24
2
Medium Priority
?
966 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 28

Accepted Solution

by:
clayfox earned 1500 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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

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…
Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project (http://www.eclipse.org/sequoyah/) automates most of the tasks discussed in this article. You can even fin…
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.
Suggested Courses

800 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