IP2007, MOSS 2007.
How can a drop down control be tie to domain group members? I have a
domain group called "hq\sales". How can a drop down gets all the names
from this group?
You mean AD group or Moss2007 user group?
in the first case i think you can by code inside yur form.. but you need
the support of other people.. i don't know how.
In the second case.. i can help you: for a long time i've searched for a
solution for a similar scope.. and finally got it (thanks to the great man
suggested the solution!)
![Smile :) :)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
So... start!
![Stick Out Tongue :p :p](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
You can retrieve the members of a group by web service! But from InfoPath
you need to manually edit the xsn source code to get it work correctly.
Setup a new connection to the usergroup.asmx and then to the
GetUserCollectionFromGroup (or anything you need); enter anything required
to setup connection.
Now probably you can notice that the structure retrived to IP it's not
what you expected.. simply nothing of usable!
Then you need to manual edit the xsn file.
To do this, you need to save the form as source into a folder.
After this step you have in that folder all the files that build the form.
Go to that folder that search for GetUserCollectionFromGroupXX.xsd, where
XX is a number: you need to search for the correct one, probably the
bigger
![Smile :) :)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
, where all the definitions for the webservice are stored.
Ok, proceed.
Edit it with a text editor (like notepad, like the opensource notepad++ or
UltraEdit or anything similar)
Now you need to write the correct definition.. i write it here, but check
it again.. syntax and according this:
http://msdn.microsoft.com/en-us/library/ms995733.aspx
<s:complexType name="GetUserCollectionFromGroupType">
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="groupName"
type="s:string"/>
<s:element minOccurs="0" maxOccurs="1" name="Users">
<s:complexType>
<s:sequence>
<s:element maxOccurs="unbounded" name="User" >
<s:complexType>
<s:attribute name="ID" type="s:unsignedShort"
use="required" />
<s:attribute name="Name" type="s:string" use="required" />
<s:attribute name="LoginName" type="s:string"
use="required" />
<s:attribute name="Email" type="s:string" use="required" />
<s:attribute name="Notes" type="s:string" use="required" />
<s:attribute name="IsSiteAdmin" type="s:string"
use="required" />
<s:attribute name="IsDomainGroup" type="s:string"
use="required" />
</s:complexType>
</s:element>
</s:sequence>
</s:complexType>
</s:element>
</s:sequence>
</s:complexType>
After setting up the new definition, we need to use it. To do this, search
for the element "<s:element name="GetUserCollectionFromGroup" ..." and
change it with
<s:element name="GetUserCollectionFromGroup"
type="tns:GetUserCollectionFromGroupType" />
Ok. Now save and close the file.
Open "as structure" in infopath the file manifest.xsf.
Check if you have the correct structure for your secondary data source.
Now you can save the form again in the xsn format.
REMEMBER to NOT edit that connection from infopath.. or you lost your
manual work on the connection.
You can check the whole procedure here
http://forums.msdn.microsoft.com/en.../thread/56a16710-b513-4da2-9ea3-351cb158e7d9/
Search for the answer I wrote inside the thread.
Hope this help.