<?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: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/28967.aspx</link><pubDate>Tue, 27 May 2008 17:47:18 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:28967</guid><dc:creator>Mikem</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/28967.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=28967</wfw:commentRss><description>&lt;p&gt;10bt,&lt;/p&gt;&lt;p&gt;&amp;nbsp;This will work for me :) but unfortunately requires everyone else to know how to do this as, to my understanding, this is only a temporary personal view. Given the nature of the application that assumption just won&amp;#39;t hold, the end users aren&amp;#39;t going to open up different views and apply custom filters. To get around this I&amp;#39;d like to provide a nice user interface just linking to different filter views but this forces me to reinvent the wheel (as I&amp;#39;m essentially ignoring SharePoint&amp;#39;s ability to filter document libraries and creating my own views which apply their own filters). As you can imagine this can be quite time consuming and unellegant given the large variety of views necessary to provide a complete capability.&lt;/p&gt;&lt;p&gt;I&amp;#39;m hoping to find a way around creating so many views. Any ideas?&lt;/p&gt;&lt;p&gt;&amp;nbsp;Thanks,&lt;/p&gt;&lt;p&gt;Mikem&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/28934.aspx</link><pubDate>Sat, 24 May 2008 16:12:51 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:28934</guid><dc:creator>10basetom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/28934.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=28934</wfw:commentRss><description>&lt;p&gt;Mikem, 
&lt;p&gt;I don&amp;#39;t have access to SharePoint right now, but I believe what you&amp;#39;re looking for already exists as of Sharepoint 2003. Here&amp;#39;s how to do a &amp;quot;contains&amp;quot; filter: 
&lt;ol&gt;
&lt;li&gt;
&lt;div&gt;From the forms library, switch to the datasheet or datagrid&amp;nbsp;view (I forget the exact terminology in SharePoint, but the view you want is similar to a spreadsheet grid).&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;Just as you would do in Excel, select the custom filter for the column(s) you want and you should be able to add a &amp;quot;contains&amp;quot; filter.&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;Cheers,&lt;br /&gt;10bt&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/28880.aspx</link><pubDate>Thu, 22 May 2008 17:42:59 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:28880</guid><dc:creator>Mikem</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/28880.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=28880</wfw:commentRss><description>&lt;p&gt;Hey 10, great post! Very helpful. I do have one add on question:&lt;/p&gt;&lt;p&gt;&amp;nbsp;The above method will do a great job of aggregating the ethnicities to an attribute which can than be filtered on. The issue that I&amp;#39;m coming across is that if i wanted to find all people who were a certain ethnicity (including someone who has multiple ethnicities) the filtering won&amp;#39;t work. So if I filtered on just Irish I would lose people who were Irish &amp;amp; Martian which in my case is bad.&lt;/p&gt;&lt;p&gt;Is there a way to get around this? I&amp;#39;m open to changing the controls if necessary but I think the check boxes provide the best interface. I can&amp;#39;t filter on a merged repeating area so that&amp;#39;s not an option (or is there a trick around this). Ultimately I care about the field &lt;b&gt;containing a certain value&lt;/b&gt; as opposed to matching a string of potentially many values. The end user filtering is my concern. I&amp;#39;m deploying the form on SharePoint and would like to avoid creating tons of custom views.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;Thanks,&lt;/p&gt;&lt;p&gt;&amp;nbsp;Mikem&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/27410.aspx</link><pubDate>Tue, 25 Mar 2008 08:03:52 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:27410</guid><dc:creator>10basetom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/27410.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=27410</wfw:commentRss><description>&lt;p&gt;Sorry, I was traveling out of state. In any case, glad you got it working. Post here if you hit any snags.&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/27406.aspx</link><pubDate>Mon, 24 Mar 2008 23:48:22 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:27406</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/27406.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=27406</wfw:commentRss><description>&lt;p&gt;Great! I&amp;#39;m happy to hear you got it working!&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/27398.aspx</link><pubDate>Mon, 24 Mar 2008 19:02:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:27398</guid><dc:creator>bcarroll3</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/27398.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=27398</wfw:commentRss><description>&lt;p&gt;found the solution to my newbie quesion.&amp;nbsp; Thanks &lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/27397.aspx</link><pubDate>Mon, 24 Mar 2008 18:51:49 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:27397</guid><dc:creator>bcarroll3</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/27397.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=27397</wfw:commentRss><description>&lt;p&gt;this looks like exactly what I&amp;#39;ve spent days searching for.&lt;/p&gt;
&lt;p&gt;I am not clear however, how one adds the script to the section control.&amp;nbsp; Right clicking on the control or bringing up properties does not provide a path to a script window.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/26462.aspx</link><pubDate>Thu, 14 Feb 2008 00:53:21 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:26462</guid><dc:creator>10basetom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/26462.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=26462</wfw:commentRss><description>&lt;p&gt;&lt;BLOCKQUOTE&gt;&lt;div&gt;&lt;img src="/Themes/infopathdev/images/icon-quote.gif"&gt; &lt;strong&gt;Greg Collins:&lt;/strong&gt;&lt;/div&gt;&lt;div&gt; 
&lt;p&gt;Thanks for sharing this with us!&lt;/p&gt;
&lt;p&gt;&lt;/div&gt;&lt;/BLOCKQUOTE&gt;&lt;/p&gt;
&lt;p&gt;Thanks for all of your insightful articles! I&amp;#39;m just giving back to the community where I can :).&lt;/p&gt;</description></item><item><title>Re: Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/26458.aspx</link><pubDate>Wed, 13 Feb 2008 23:06:44 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:26458</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/26458.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=26458</wfw:commentRss><description>&lt;p&gt;Thanks for sharing this with us!&lt;/p&gt;</description></item><item><title>Displaying multiple checkbox values in one SharePoint column</title><link>https://www.infopathdev.com:443/forums/thread/26154.aspx</link><pubDate>Fri, 01 Feb 2008 08:04:36 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:26154</guid><dc:creator>10basetom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/26154.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=26154</wfw:commentRss><description>Hello,&lt;br /&gt;&lt;br /&gt;
&lt;p&gt;I&amp;#39;m sure lots of people have encountered this problem before and have come up with different, and even the same, solutions to this. This is an account of how I did it...&lt;/p&gt;
&lt;p&gt;Imagine having a form that allows people to pick their ethnicities. Since interracial marriages is a growing trend these days, you&amp;#39;ll need to use checkbox controls instead of the old-school radio button controls:&lt;/p&gt;
&lt;p&gt;&lt;font face="courier new,courier"&gt;[ ] African &lt;font face="arial,helvetica,sans-serif"&gt;(field name = &amp;#39;African&amp;#39;)&lt;/font&gt;&lt;br /&gt;[ ]&amp;nbsp;Dominican Republican &lt;/font&gt;&lt;font face="arial,helvetica,sans-serif"&gt;(field name = &amp;#39;Domican_Republican&amp;#39;)&lt;/font&gt;&lt;font face="courier new,courier"&gt;&lt;br /&gt;[ ] Irish &lt;font face="arial,helvetica,sans-serif"&gt;(field name = &amp;#39;Irish&amp;#39;)&lt;/font&gt;&lt;br /&gt;[ ] Martian &lt;font face="arial,helvetica,sans-serif"&gt;(field name = &amp;#39;Martian&amp;#39;)&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;When the form is published to SharePoint, you may want to have all of the checked values show up in one column instead of four individual columns. Since checkbox controls, unlike radio button controls, hold a collection of values instead of just one value, you&amp;#39;ll need to do some coding in order to accomplish the simple feat of displaying multiple checkbox values in one SharePoint column.&lt;/p&gt;
&lt;p&gt;One way to do it is&amp;nbsp;to create a hidden field; let&amp;#39;s call it &lt;font face="courier new,courier"&gt;&lt;strong&gt;origins&lt;/strong&gt;&lt;/font&gt;. This field will contain a concatenated, comma-separated list of the checked values that will be displayed on SharePoint. In the Data Source panel, create a container (parent) group for these checkboxes; let&amp;#39;s call it &lt;font face="courier new,courier"&gt;&lt;strong&gt;origins_group&lt;/strong&gt;&lt;/font&gt;. The &lt;font face="courier new,courier"&gt;origins_group&lt;/font&gt; is optional, but is highly recommended unless you are masochistic and want to create an event handler for each checkbox control ;).&lt;/p&gt;
&lt;p&gt;The next step is to create an OnAfterChange event handler for the &lt;font face="Courier New"&gt;origins_group&lt;/font&gt; group, leveraging the behavior&amp;nbsp;that&amp;nbsp;&amp;quot;bubbles&amp;quot; changes from the nested checkbox controls (children) to the parent&amp;nbsp;&lt;font face="Courier New"&gt;origins_group&lt;/font&gt;.&amp;nbsp;This function basically walks through the&amp;nbsp;&lt;font face="Courier New"&gt;origins_group&lt;/font&gt; node and concatenates all of the values in its child nodes that are elements (nodeType = 1) and contain the &amp;quot;true&amp;quot; value (checked). There are a couple of regular expressions that convert underscores to spaces and removes the trailing comma in the concatenated string before it is ouputted to the &lt;font face="courier new,courier"&gt;origins&lt;/font&gt; field.&lt;/p&gt;
&lt;p&gt;To prevent the&amp;nbsp;&lt;font face="Courier New"&gt;origins_group&lt;/font&gt; OnAfterChange event from firing needlessly, you should introduce conditional criteria such as &lt;font face="courier new,courier"&gt;if (eventObj.Operation==&amp;#39;Insert&amp;#39;)&lt;/font&gt; to ensure that the event is only triggered when a node is being inserted (every checkbox change results in the delete operation of the old value&amp;nbsp;followed by&amp;nbsp;a node insertion of the new value).&lt;/p&gt;
&lt;p&gt;Here&amp;#39;s the complete code:&lt;/p&gt;
&lt;p&gt;&lt;font style="BACKGROUND-COLOR:#ffff66;" face="courier new,courier"&gt;var oOrigins = XDocument.DOM.selectSingleNode(&amp;#39;my:myFields/my:origins&amp;#39;);&lt;br /&gt;var oOriginsGroup = XDocument.DOM.selectSingleNode(&amp;#39;my:myFields/my:origins_group&amp;#39;);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font style="BACKGROUND-COLOR:#ffff66;" face="courier new,courier"&gt;function msoxd_my_origins_group::OnAfterChange(eventObj) {&lt;br /&gt;&amp;nbsp; if (eventObj.IsUndoRedo) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // An undo or redo operation has occurred and the DOM is read-only.&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;&amp;nbsp; // A field change has occurred and the DOM is writable. Write code here to respond to the changes.&lt;br /&gt;&amp;nbsp; if (eventObj.Operation==&amp;#39;Insert&amp;#39;) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var str = &amp;#39;&amp;#39;;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var arr = oOriginsGroup.childNodes;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (var i=0; i&amp;lt;arr.length; i++) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (arr[i].nodeType==1 &amp;amp;&amp;amp; arr[i].text==&amp;#39;true&amp;#39;) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; str += arr[i].nodeName.replace(/my:(\w+)/,&amp;#39;$1, &amp;#39;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; str = str.replace(/_/g,&amp;#39; &amp;#39;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; str = str.replace(/, $/,&amp;#39;&amp;#39;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; oOrigins.text = str;&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;}&lt;/font&gt;&lt;/p&gt;Cheers,&lt;br /&gt;Tom</description></item></channel></rss>