<?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: Linking Toolbar Buttons to Script Functions</title><link>https://www.infopathdev.com:443/forums/thread/13663.aspx</link><pubDate>Wed, 21 Dec 2005 06:08:08 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:13663</guid><dc:creator>qwer</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/13663.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=13663</wfw:commentRss><description>Greg,&lt;br /&gt;&lt;br /&gt;I tried this way in VB script but does not seem to work. I used instead:&lt;br /&gt;&lt;br /&gt;Sub foo_OnClick(eventObj)&lt;br /&gt;&lt;br /&gt;End Sub&lt;br /&gt;&lt;br /&gt;No matter what code I put in there it just says script error exist. Please help, anyone?</description></item><item><title>Re: Linking Toolbar Buttons to Script Functions</title><link>https://www.infopathdev.com:443/forums/thread/13662.aspx</link><pubDate>Thu, 29 Sep 2005 16:28:26 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:13662</guid><dc:creator>Gumboot</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/13662.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=13662</wfw:commentRss><description>That worked thanks,&lt;br /&gt;</description></item><item><title>Re: Linking Toolbar Buttons to Script Functions</title><link>https://www.infopathdev.com:443/forums/thread/13661.aspx</link><pubDate>Wed, 28 Sep 2005 21:20:13 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:13661</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/13661.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=13661</wfw:commentRss><description>The xsf:button element has a name attribute which defines which OnClick handler to associate with the button. So if you had:&lt;br /&gt;&lt;br /&gt;&amp;lt;xsf:button name="foo"... /&amp;gt;&lt;br /&gt;&lt;br /&gt;then when you click that button it calls into your script looking for:&lt;br /&gt;&lt;br /&gt;function foo()&lt;br /&gt;{...}&lt;br /&gt;&lt;br /&gt;I don't recall if you need to format the function like any other OnClick handler. If that is the case your function will look like:&lt;br /&gt;&lt;br /&gt;function foo::OnClick(eventObj)&lt;br /&gt;{...}&lt;br /&gt;&lt;br /&gt;Greg Collins [InfoPath MVP]&lt;br /&gt;InfoPath Dev</description></item><item><title>Linking Toolbar Buttons to Script Functions</title><link>https://www.infopathdev.com:443/forums/thread/12586.aspx</link><pubDate>Tue, 27 Sep 2005 17:40:27 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:12586</guid><dc:creator>Gumboot</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/12586.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=12586</wfw:commentRss><description>I've been looking at the MS examples of creating custom Toolbar buttons, however they do not show how to link them to actual scripts embedded in the Form.  &lt;br /&gt;&lt;br /&gt;Does someone have an example for me to look at? &lt;br /&gt;&lt;br /&gt;Many thanks in Advance</description></item></channel></rss>