<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>General</title><link>https://www.infopathdev.com:443/forums/41.aspx</link><description>If you're not sure where to ask your question, ask it here. If necessary, our moderators will make sure it gets classified in the correct board.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/36129.aspx</link><pubDate>Sat, 20 Dec 2008 20:23:17 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:36129</guid><dc:creator>Alec Pojidaev</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/36129.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=36129</wfw:commentRss><description>&lt;p&gt;That might help:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://alecpojidaev.wordpress.com/2008/12/16/infopath-codeless-programming-walkthrough/"&gt;http://alecpojidaev.wordpress.com/2008/12/16/infopath-codeless-programming-walkthrough/&lt;/a&gt;&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34730.aspx</link><pubDate>Fri, 21 Nov 2008 16:35:00 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34730</guid><dc:creator>cathy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34730.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34730</wfw:commentRss><description>&lt;p&gt;Could you please tell me how can I loop through the group with XPathNavigator to achieve the above? I mean foreach().&lt;/p&gt;
&lt;p&gt;Any example would be greately appreciable.&lt;/p&gt;
&lt;p&gt;TIA&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34607.aspx</link><pubDate>Thu, 20 Nov 2008 15:19:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34607</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34607.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34607</wfw:commentRss><description>&lt;p&gt;The code sample is using the IP 2003 object model. If you are using IP 2007, you can either set your form to use C# 2003 compatible for the programming language or modify the code to use the 2007 OM. &lt;a href="http://msdn.microsoft.com/en-us/library/bb643160.aspx"&gt;This&lt;/a&gt; MSDN article has some information on the differences.&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34599.aspx</link><pubDate>Thu, 20 Nov 2008 14:21:47 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34599</guid><dc:creator>chandrakanth</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34599.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34599</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The code that i have mentioned is completly C#. Please check the below namaspace.&lt;/p&gt;
&lt;p&gt;using Microsoft.Office.Interop.InfoPath.SemiTrust;&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34596.aspx</link><pubDate>Thu, 20 Nov 2008 14:12:36 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34596</guid><dc:creator>cathy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34596.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34596</wfw:commentRss><description>&lt;p&gt;&amp;lt;p&amp;gt;&lt;/p&gt;
&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I got a similar requirement! and was trying this code.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;it looks like&amp;nbsp;this code&amp;nbsp;was written in C++. what is the equivalent code for C#?&amp;nbsp; IXMLDOMNode is not present in C# or am I missing any namespace?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34318.aspx</link><pubDate>Sat, 15 Nov 2008 09:18:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34318</guid><dc:creator>chandrakanth</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34318.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34318</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Add a field (named as &amp;quot;EmailAddresses&amp;quot;) in the main schema .In the submit data connection choose &amp;quot;EmailAddresses&amp;quot; as the To field. Now in the &amp;quot;group1&amp;quot; OnAfterChange event. Please write the below lines of code.&lt;/p&gt;
&lt;p&gt;Note: The below code is in C#.net .&lt;/p&gt;
&lt;p&gt;[InfoPathEventHandler(MatchPath = &amp;quot;/my:myfields/my:group1&amp;quot;, EventType = InfoPathEventType.OnAfterChange)]&lt;br /&gt;public void group1_OnAfterChange(DataDOMEvent e)&lt;br /&gt;{&lt;/p&gt;
&lt;p&gt;&amp;nbsp;if (e.IsUndoRedo || e.Operation != &amp;quot;Insert&amp;quot; || e.Site.baseName != &amp;quot;group1&amp;quot;)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IXMLDOMNodeList personNodeList = GetNodes(&amp;quot;/my:GMO/my:group1/my:Person&amp;quot;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string userNameFromAccountID = string.Empty;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string userNameEmailAddress = string.Empty;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; foreach (IXMLDOMNode personNode in personNodeList)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (GetNodeValue(personNode, &amp;quot;my:AccountId&amp;quot;) != string.Empty)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string accountID = GetNodeValue(personNode, &amp;quot;my:AccountId&amp;quot;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int position = accountID.LastIndexOf(&amp;quot;\\&amp;quot;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; position = position + 1;&lt;br /&gt;&amp;nbsp;&amp;nbsp;userNameFromAccountID = accountID.Substring(position, (accountID.Length - position));&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string domainName = accountID.Substring(0, position);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;br /&gt;&amp;nbsp;&amp;nbsp;userNameEmailAddress = userNameEmailAddress + userNameFromAccountID + &amp;quot;@&amp;quot; + domainName + &amp;quot;.com&amp;quot; + &amp;quot;;&amp;quot; ;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&amp;nbsp;thisXDocument.DOM.selectSingleNode(&amp;quot;/my:myfields/my:EmailAddresses&amp;quot;).text = userNameEmailAddress;&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;Please let me know if you want any help in understanding the above code.&lt;/p&gt;</description></item><item><title>Re: Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/34312.aspx</link><pubDate>Sat, 15 Nov 2008 07:08:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:34312</guid><dc:creator>ravig</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/34312.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=34312</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Take a string and append all the contact selector field values to the string.&lt;/p&gt;
&lt;p&gt;ex: name = name + GetNodeValue(&amp;quot;field xPath&amp;quot;)&lt;/p&gt;
&lt;p&gt;and give this string in the &amp;quot;To&amp;quot; of email option&lt;/p&gt;</description></item><item><title>Contact Selector Control - cannot e-mail to selected contact.</title><link>https://www.infopathdev.com:443/forums/thread/31430.aspx</link><pubDate>Wed, 13 Aug 2008 15:03:52 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:31430</guid><dc:creator>Catharine</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/31430.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=31430</wfw:commentRss><description>&lt;p&gt;Hi,&amp;nbsp; I have created a form with several contact selectors.&amp;nbsp; I can search for the contact fine.&amp;nbsp; But I don&amp;#39;t seem to be able to use the results of the query.&lt;/p&gt;
&lt;p&gt;My structure is....&lt;/p&gt;
&lt;p&gt;group1&lt;br /&gt;&amp;nbsp; Person&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DisplayName&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AccountId&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AccountType&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AD&lt;br /&gt;AccountVal&lt;/p&gt;
&lt;p&gt;On submit I want to email the selected contact.&amp;nbsp; In the submit data connection I choose group1 as the To field.&amp;nbsp; On submit I get an error The following addresses did not resolve in the To line: Ormerod, Catharine&amp;nbsp; DTIN\OrmerC User&amp;nbsp; I presume I am using the wrong field - but none of the other fields holds the email address which&amp;nbsp;should be in the form&amp;nbsp;(&lt;a href="mailto:name@company.com"&gt;name@company.com&lt;/a&gt;).&amp;nbsp; What am I doing wrong ?&lt;/p&gt;
&lt;p&gt;I do have a webservice which will get the correct e-mail address if it is given the username BUT for that to work I have to separate the domain from the username in AccoundId.&amp;nbsp; I have not been able to do that either.....&lt;/p&gt;
&lt;p&gt;I tried a couple of things...&lt;/p&gt;
&lt;p&gt;1. Adding a field (AD) to the Person Repeating group. (The Contact Selector still worked with the additional field).&amp;nbsp; I put a default value of sub substring-after(AccountId, &amp;quot;DTIN\&amp;quot;) - but this did not return any value at all - I also added a rule to AccountId to set the value of AD - again nothing happened&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;2. Adding a field (AccountVal) outside the Person repeating group. + a rule on AccountId which &amp;nbsp;sets the value of AccountVal &lt;/p&gt;
&lt;p&gt;I have finally been able to separate off the username by putting a rule on group1 which sets the value of AccountVal.&amp;nbsp; I am worried that this will&amp;nbsp;crash if the user selects more than one contact.&amp;nbsp;- Is this the only way to do it ?&amp;nbsp; Why did my other attempts not work.&lt;/p&gt;
&lt;p&gt;Thank you for reading&lt;/p&gt;
&lt;p&gt;Catharine&lt;/p&gt;</description></item></channel></rss>