<?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: OnClick: Wrong number of arguments or invalid property assignment</title><link>https://www.infopathdev.com:443/forums/thread/40899.aspx</link><pubDate>Thu, 23 Apr 2009 07:50:19 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40899</guid><dc:creator>Zeetec</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40899.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=40899</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;I managed to find a way around that now.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;This was my code (highlighted code is what I added in to get it to work):-&lt;/p&gt;
&lt;p&gt;&lt;span&gt;function CTRL23_5::OnClick(eventObj)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;MainSubmit = XDocument.DataAdapters.&lt;b&gt;&lt;span style="FONT-WEIGHT:bold;"&gt;Item&lt;/span&gt;&lt;/b&gt;(&amp;quot;Main submit&amp;quot;);&lt;br /&gt;&amp;nbsp;emailSubmit = XDocument.DataAdapters.&lt;b&gt;&lt;span style="FONT-WEIGHT:bold;"&gt;Item&lt;/span&gt;&lt;/b&gt;(&amp;quot;Submit for Approval&amp;quot;);&lt;br /&gt;&amp;nbsp;emailSubmit.Submit();&lt;br /&gt;&amp;nbsp;MainSubmit.Submit();&lt;br /&gt;&amp;nbsp;Application.ActiveWindow.Close(&lt;b&gt;&lt;span style="FONT-WEIGHT:bold;"&gt;true&lt;/span&gt;&lt;/b&gt;);&lt;br /&gt;}&lt;/span&gt;&lt;/p&gt;&lt;span&gt;&lt;/span&gt;&lt;font color="#006600"&gt;&lt;span&gt;that&amp;#39;s all it needed and it got rid of that error!&lt;/span&gt;&lt;/font&gt;&lt;font color="#006600"&gt;&lt;span&gt; 
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;/span&gt;&lt;/font&gt;</description></item><item><title>Re: OnClick: Wrong number of arguments or invalid property assignment</title><link>https://www.infopathdev.com:443/forums/thread/40889.aspx</link><pubDate>Thu, 23 Apr 2009 04:55:22 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40889</guid><dc:creator>swathip</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40889.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=40889</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I think you are using some parameters in the calling of the function which is used to submit the form. Can you paste the code here that you are using in onclick event? &lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>OnClick: Wrong number of arguments or invalid property assignment</title><link>https://www.infopathdev.com:443/forums/thread/40847.aspx</link><pubDate>Wed, 22 Apr 2009 09:06:54 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40847</guid><dc:creator>Zeetec</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40847.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=41&amp;PostID=40847</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;I have a submit button on my form. When clicked it saves the form to my document library and also sends an email to the next person (for example Fred)&lt;/p&gt;
&lt;p&gt;The person&amp;#39;s email is stored in a textbox called &amp;#39;Email&amp;#39;. I have created a rule in my form options which says:-&lt;/p&gt;
&lt;p&gt;If the Name field = Joe Bloggs then populate Fred&amp;#39;s email into the &amp;#39;Email&amp;#39; textbox.&lt;/p&gt;
&lt;p&gt;But when I click on the submit button it comes up with this error:-&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;OnClick: Wrong number of arguments or invalid property assignment&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;When I click OK to this it still submits the form correctly!&lt;/p&gt;
&lt;p&gt;&amp;nbsp;How can I get rid of this error?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Thanks.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>