<?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>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Can I Iterate through InfoPath fields by type?</title><link>https://www.infopathdev.com:443/forums/thread/64451.aspx</link><pubDate>Tue, 22 Feb 2011 15:27:38 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:64451</guid><dc:creator>xenondiver</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/64451.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=64451</wfw:commentRss><description>&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;Hi&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;I use the XmlFormView control in a Sharepoint webpart&amp;nbsp;to display InfoPath forms.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Having loaded an InfoPathForm to the XmlFormView control is it possible to iterate through InfoPath fields/controls programatically by their element&amp;nbsp;type? &lt;br /&gt;I would like to iterate through all attachment controls but without relying on the control name (i.e. my:Attachment). In&amp;nbsp;pseudocode what I want is to do this for attachment fields:&lt;/p&gt;
&lt;p&gt;Foreach&amp;nbsp;field in InfoPathForm&lt;br /&gt;{&lt;br /&gt;if(field is base64Binary)&lt;br /&gt;&amp;nbsp;do something &lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;Christer&lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>