Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / February 2006

Tip: Looking for answers? Try searching our database.

how do I save a form on disk using submit button

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Lazy thicko needs to know... - 20 Nov 2005 18:16 GMT
I want to create a file of completed forms. Each form is to be stored locally
(on C:) using C:path\(data from form) as a filename.
Franck Dauché - 20 Nov 2005 20:59 GMT
Hi,

Try to use:
thisApplication.ActiveWindow.XDocument.SaveAs(YourPath);
where YourPath is C:path\filename

Regards,

Franck Dauché

> I want to create a file of completed forms. Each form is to be stored locally
> (on C:) using C:path\(data from form) as a filename.
Caeanis - 05 Feb 2006 11:51 GMT
I am trying this with the following code, but I get an run-time error message
when I attempt to use it:  "The form does not have a file name".  The xpath
query although long does work, the messagebox returns the right value for
that node, and I have also tried using the save method instead of the saveas
method.  Both generate errors.

 Dim myPath, objXMLNode
 Set objXMLNode = XDocument.DOM.selectSingleNode("/*[local-name()='Recipe'
and
namespace-uri()='http://schemas.microsoft.com/office/infopath/2003/myXSD/2005-10-08T23:36:28']/*[
local-name()='Header
'
and
namespace-uri()='http://schemas.microsoft.com/office/infopath/2003/myXSD/2005-10-08T23:36:28'][1]
/*[local-name()='Name
'
and
namespace-uri()='http://schemas.microsoft.com/office/infopath/2003/myXSD/2005-10-08T23:36:28'][1]")
 myPath = "C:\Inetpub\wwwroot\" &  objXMLNode.text & ".xml"
 Msgbox "You are about to save the following file: " & objXMLNode.text &
".xml"
 XDocument.SaveAs(myPath)

> Hi,
>
[quoted text clipped - 8 lines]
> > I want to create a file of completed forms. Each form is to be stored locally
> > (on C:) using C:path\(data from form) as a filename.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.