Group:  Other Microsoft Office Products ยป microsoft.public.infopath
Thread: OnSaveRequest errors out on WYSE terminals???

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

OnSaveRequest errors out on WYSE terminals???
"~john" <SonVoltMMA[ at ]gmail.com> 31.07.2006 22:34:42
I'm storing infopath forms in a sharepoint library and I've added code
to change the filename to the contents of a text box when the user hits
save. Everything works fine when using the form on my computer (a PC)
but when I try to save the form through a WYSE terminal it give's an
error.


"The following error occurred:

The specified location is either not valid or not available

Check the spelling of the filename, and verify that the location is
correct
File:script.js
Line: 53"

Here's the code for my save button

function XDocument::OnSaveRequest(eventObj)
{

if (XDocument.IsNew == true || eventObj.IsSaveAs == false)
{
//string fileName =
XDocument.DOM.selectSingleNode("//my:subject").text;

XDocument.UI.SetSaveAsDialogFileName(
XDocument.DOM.selectSingleNode("//my:subject").text );

// Write the code to be run before saving here
eventObj.IsCancelled = eventObj.PerformSaveOperation();

// Write the code to be run after saving here.
eventObj.ReturnStatus = true;

}
else
{
eventObj.IsCancelled = eventObj.PerformSaveOperation();
eventObj.ReturnStatus = true;
}



}

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net