<?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: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/63856.aspx</link><pubDate>Thu, 03 Feb 2011 14:05:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:63856</guid><dc:creator>KaSper</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/63856.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=63856</wfw:commentRss><description>Please,help me! I have error :Object required


How can I fix the problem?



Code:
function XDocument::OnSaveRequest(eventObj)
{
 var Order = XDocument.DOM.selectSingleNode(&amp;quot;/my:myFields/my:OrderNr&amp;quot;);


XDocument.UI.Alert(Order.text);


if (XDocument.IsNew == true || eventObj.IsSaveAs == false)
{
if (eventObj.IsSaveAs == true)
{
XDocument.UI.SetSaveAsDialogFileName(Order.text);
}
eventObj.IsCancelled = eventObj.PerformSaveOperation();
}
eventObj.ReturnStatus = true;
}</description></item><item><title>Re: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/14079.aspx</link><pubDate>Sat, 03 Dec 2005 13:33:03 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14079</guid><dc:creator>kssandhu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14079.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14079</wfw:commentRss><description>That solved it.  Thanks</description></item><item><title>Re: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/14078.aspx</link><pubDate>Fri, 02 Dec 2005 20:35:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14078</guid><dc:creator>Matt Faus</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14078.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14078</wfw:commentRss><description>That means that with your query statement you are not retrieving the node.  Your XPath looks a little screwy, try something more like this:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;GMSRef = XDocument.DOM.selectSingleNode("/my:myFields/my:group3/my:Date");&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;---------------&lt;br /&gt;Matt Faus&lt;br /&gt;</description></item><item><title>Re: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/14077.aspx</link><pubDate>Fri, 02 Dec 2005 19:40:28 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14077</guid><dc:creator>kssandhu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14077.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14077</wfw:commentRss><description>I now get an Object Required error.  I am using Jscript in case that makes a difference.</description></item><item><title>Re: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/14076.aspx</link><pubDate>Fri, 02 Dec 2005 17:36:58 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14076</guid><dc:creator>Agni Jonnalagadda</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14076.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14076</wfw:commentRss><description>Hi,&lt;br /&gt;You are passing the node instead of string value to SetSaveAsDialogFileName.&lt;br /&gt;&lt;br /&gt;Code should be&lt;br /&gt;GMSRef = XDocument.DOM.selectSingleNode("my:myFields/group3:Date");&lt;br /&gt;XDocument.UI.SetSaveAsDialogLocation("c:\\test");&lt;br /&gt;XDocument.UI.SetSaveAsDialogFileName(GMSRef.text);&lt;br /&gt;&lt;br /&gt;Hope this code works for you!&lt;br /&gt;&lt;br /&gt;Agni&lt;br /&gt;InfoPath Dev India</description></item><item><title>Re: Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/14075.aspx</link><pubDate>Fri, 02 Dec 2005 09:38:03 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14075</guid><dc:creator>Patrick Halstead</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14075.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14075</wfw:commentRss><description>Hi Kssandhu and welcome to our forum,&lt;br /&gt;This is easy. I've asked Agni to respond.&lt;br /&gt;&lt;br /&gt;Patrick Halstead [InfoPath MVP]&lt;br /&gt;InfoPathDev</description></item><item><title>Using Form Options   Open Save</title><link>https://www.infopathdev.com:443/forums/thread/12703.aspx</link><pubDate>Thu, 01 Dec 2005 20:25:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:12703</guid><dc:creator>kssandhu</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/12703.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=12703</wfw:commentRss><description>Trying to utilize the script option for Open Save within Form Options to pre-fill the save path and file name&lt;br /&gt;In particular I want to set the SaveAsDialogFilename with the contents of 2 fields concatenated together.  Code below generates errors. &lt;br /&gt;&lt;br /&gt;DIM GMSRef;&lt;br /&gt;GMSRef = XDocument.DOM.selectSingleNode("my:myFields/group3:Date");&lt;br /&gt;UI.SetSaveAsDialogLocation("c:/test");&lt;br /&gt;UI.SetSaveAsDialogFileName(GMSRef);&lt;br /&gt;&lt;br /&gt;Replacing&lt;br /&gt;UI.SetSaveAsDialogFileName("xyz") pre-populates form with xyz as file name&lt;br /&gt;&lt;br /&gt;any ideas on how to get this to work.</description></item></channel></rss>