<?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: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96321.aspx</link><pubDate>Wed, 05 Mar 2014 15:04:11 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96321</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96321.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96321</wfw:commentRss><description>&lt;p&gt;So you&amp;#39;re using code to submit to the DB server? In that case you may need code, though the recommended practice is to use a web service (such as DBXL) as an intermediary for submitting to a database. That would save you from having to keep code in the form itself.&lt;/p&gt;&lt;p&gt;It looks like there&amp;#39;s at least one more mistake in your XPath. You need to change &lt;strong&gt;my:DisplayName&lt;/strong&gt; to &lt;strong&gt;pc:DisplayName&lt;/strong&gt;, but even if the XPath is correct, the people picker could be empty, so you should be checking for nulls.&lt;/p&gt;&lt;p&gt;As you&amp;#39;ve surmised, there isn&amp;#39;t a way to put action rules on people pickers, but a way around this is to create a hidden field whose default value formula references one of the fields in the people picker. Then you can put action rules on that hidden field and they will execute when the value of the people picker changes.&lt;/p&gt;</description></item><item><title>Re: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96320.aspx</link><pubDate>Wed, 05 Mar 2014 14:24:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96320</guid><dc:creator>jdwilliams</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96320.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96320</wfw:commentRss><description>Actually I am having trouble creating an action rule for the people picker. Not sure if you can do that.</description></item><item><title>Re: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96319.aspx</link><pubDate>Wed, 05 Mar 2014 14:18:34 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96319</guid><dc:creator>jdwilliams</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96319.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96319</wfw:commentRss><description>I also like the idea of using a hidden field. I can definitely do that.</description></item><item><title>Re: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96318.aspx</link><pubDate>Wed, 05 Mar 2014 14:16:58 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96318</guid><dc:creator>jdwilliams</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96318.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96318</wfw:commentRss><description>Thanks for the replies. I tried taking the My&amp;quot; part out. I now have an error that says &amp;quot;NullReferenceException was unhanded by user code. Use the &amp;quot;new&amp;quot; keyword to create an object instance.

But to your question, I am trying to submit this data to SQL Server. This is the only way I know how to accomplish that. Can you possible explain to me what you mean by using simple rules to do this?</description></item><item><title>Re: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96315.aspx</link><pubDate>Wed, 05 Mar 2014 09:31:15 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96315</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96315.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96315</wfw:commentRss><description>&lt;p&gt;There shouldn&amp;#39;t be a &lt;strong&gt;my:&lt;/strong&gt; here:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&amp;nbsp;my:pc:Person&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;But is there a reason you&amp;#39;re using code to do this? It seems like something you could do with regular rules.&lt;/p&gt;</description></item><item><title>Re: Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96314.aspx</link><pubDate>Wed, 05 Mar 2014 08:48:20 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96314</guid><dc:creator>wilkies0106aw</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96314.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96314</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;Why not add a hidden text field which just display the Display Name field of the people picker control?&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Extracting/Submitting DisplayName form people picker</title><link>https://www.infopathdev.com:443/forums/thread/96299.aspx</link><pubDate>Tue, 04 Mar 2014 18:30:39 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:96299</guid><dc:creator>jdwilliams</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/96299.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=96299</wfw:commentRss><description>I am trying to grab DisplayName from the people picker. I have this string: 

user = xNavigator.SelectSingleNode(&amp;quot;/my:myFields/my:group/my:pc:Person/my:DisplayName&amp;quot;, NamespaceManager).Value;

When I go to submit the form I get this error: 

&amp;#39;/my:myFields/my:group/my:pc:Person/my:DisplayName&amp;#39; has an invalid token.

Can&amp;#39;t figure out what the deal is. Any help would be appreciated.</description></item></channel></rss>