<?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>Code</title><link>https://www.infopathdev.com:443/forums/45.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20638.aspx</link><pubDate>Tue, 12 Jun 2007 16:22:49 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20638</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20638.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20638</wfw:commentRss><description>Great! Hopefully they will add it. I know I could definitely use that feature!</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20607.aspx</link><pubDate>Tue, 12 Jun 2007 00:34:14 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20607</guid><dc:creator>YoungSC</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20607.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20607</wfw:commentRss><description>&lt;p&gt;OK good to know.&lt;/p&gt;&lt;p&gt;Thanks Greg&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20588.aspx</link><pubDate>Mon, 11 Jun 2007 16:49:11 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20588</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20588.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20588</wfw:commentRss><description>&lt;p&gt;I know that this is a common request for a future release of InfoPath. While I can&amp;#39;t speak for Microsoft and I don&amp;#39;t have any specifics as to&amp;nbsp;what features they plan for their next release (nor would I be able to divulge them if I did), I do know that they are at least aware of the idea you mentioned. Whether such a feature is incorporated in the next release won&amp;#39;t be known until they are ready to announce the new feature set (which won&amp;#39;t be for quite some time).&lt;/p&gt;&lt;p&gt;In the mean time, when you have timing issues like this where code must run first before rules, you will need to just ensure that the rule functionality is incorporated into the code. This will guarantee all items run in the correct order.&lt;/p&gt;&lt;p&gt;Good luck.&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20563.aspx</link><pubDate>Mon, 11 Jun 2007 07:13:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20563</guid><dc:creator>YoungSC</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20563.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20563</wfw:commentRss><description>&lt;p&gt;Hi Greg,&lt;/p&gt;&lt;p&gt;I know Microsoft usually seek feedback for improvements to their product and as an MVP, maybe it would have more pull coming from you (if you agree with the suggestion).&lt;/p&gt;&lt;p&gt;What would be useful in a new InfoPath version would be to add a selection to the &amp;#39;Action&amp;#39; drop down within the Rules wizard to include something like &amp;#39;Run Code Event&amp;#39;.&amp;nbsp;&amp;nbsp;You could define the sub routine name in a text box, write the sub routine,&amp;nbsp;and then InfoPath would run it as part of a rule.&lt;/p&gt;&lt;p&gt;It would certainly be more useful to some of the work I am doing and would provide greater flexibility for designers.&lt;/p&gt;&lt;p&gt;Just a thought.&lt;/p&gt;&lt;p&gt;Simon&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20512.aspx</link><pubDate>Thu, 07 Jun 2007 20:50:41 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20512</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20512.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20512</wfw:commentRss><description>&lt;p&gt;Whatever fields you have bound to that datasource are going to be changed when you do the query. That&amp;#39;s the nature of the beast. When you query, it returns a set of data. Any controls that bind to that datasource are going to be updated with that new set of data.&lt;/p&gt;&lt;p&gt;If you don&amp;#39;t want that to happen, then you need to have a separate data adapter to do your querying, and after the query has completed, copy over values from that datasource to the one your fields are bound to.&lt;/p&gt;&lt;p&gt;Sorry if I&amp;#39;m not understanding something.&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20496.aspx</link><pubDate>Thu, 07 Jun 2007 08:10:28 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20496</guid><dc:creator>Raoul</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20496.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20496</wfw:commentRss><description>&lt;p&gt;Hi Greg,&lt;/p&gt;&lt;p&gt;thank you for your clear answer, but I have last question. If I use second option and call query() function from code, all datafields on my forms (I have 3 views of datafields) are automatically filled with data after query execution, or I can fill any single field (a lot of fields!) via code?&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20467.aspx</link><pubDate>Wed, 06 Jun 2007 16:26:24 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20467</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20467.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20467</wfw:commentRss><description>&lt;p&gt;You have two options:&lt;/p&gt;&lt;p&gt;1. Move all the code to rules. This might be possible if you are not doing anything fancy and just filling in the query fields.&lt;br /&gt;2. Move all the rules to code. This is probably easier and safer for a couple of reasons:&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; a) Sounds like all you have is the query. This can be done in code by calling the Query() function on the data connection (search this site for examples).&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; b) You can use try/catch to get better error handling than the yucky error message InfoPath provides if something goes wrong.&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20447.aspx</link><pubDate>Wed, 06 Jun 2007 07:21:38 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20447</guid><dc:creator>Raoul</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20447.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20447</wfw:commentRss><description>&lt;p&gt;Hi Greg,&lt;/p&gt;&lt;p&gt;thank you for reply. My problem now is to submit a &amp;quot;query_rule&amp;quot; execution after queryfields fill up. Is there a way to submit from code&amp;nbsp;the execution of a &amp;quot;query_rule&amp;quot; (with datafields fill up automation)?&amp;nbsp;Also have you idea for another way to do this?&lt;/p&gt;&lt;p&gt;Thanks in advance.&lt;/p&gt;</description></item><item><title>Re: Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20435.aspx</link><pubDate>Tue, 05 Jun 2007 20:24:31 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20435</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20435.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20435</wfw:commentRss><description>&lt;p&gt;Refer to: &lt;a href="http://www.infopathdev.com/blogs/greg/archive/2004/07/15/Order-of-Processing-at-OnClick.aspx"&gt;http://www.infopathdev.com/blogs/greg/archive/2004/07/15/Order-of-Processing-at-OnClick.aspx&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Sorry, there is no way to change this order.&lt;/p&gt;</description></item><item><title>Code or rules priority ?</title><link>https://www.infopathdev.com:443/forums/thread/20419.aspx</link><pubDate>Tue, 05 Jun 2007 14:18:06 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:20419</guid><dc:creator>Raoul</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/20419.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=20419</wfw:commentRss><description>I have a button with code (onclick event) and rule (query submit). Through vbs code I fill query fields, and with query submit rule I try to submit my query, but query appair to start before query fields are filled. There is a way to change priority execution or wait after fields are fill up? Thank you.</description></item></channel></rss>