Open form from a SP form library - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Open form from a SP form library

Last post 03-17-2009 09:09 AM by doit007. 7 replies.
Page 1 of 1 (8 items)
Sort Posts: Previous Next
  • 04-04-2005 07:06 AM

    Open form from a SP form library

    I have an InfoPath form that sites on SharePoint form library
    I have the URL to this form (the user can open an instance of the form by that link).
    Let's say that this is the link
    http://MyServer/MyForms/template.xml

    I have an ASP/HTML page that contain button, click on this button should open me an instance of the form (by javascript).
    What should be my script for doing this?
  • 04-05-2005 04:57 AM In reply to

    Re: Open form from a SP form library

    Here is the jscript that would be used to create a new instance given a solution file. If you want to give an xml file instead of the solution file then call New instead of NewFromSolution.

    var oApp = new ActiveXObject("InfoPath.Application");

    //Open an InfoPath document from the published template
    var oXDocumentCollection = oApp.XDocuments;
    var oXDocument = oXDocumentCollection.NewFromSolution("http://MyServer/MyForms/template.xsn");

    If you want to pass some values in your aspx to this form -> you can do that by setting the xml values in the DOM. Get the node where you want to set value by calling oXDocument.DOM.selectSingleNode("XPath"); and then set the node's value.

    Shanthi
    InfoPathDev India
    Shanthi Reddy
  • 04-24-2005 12:29 PM In reply to

    Re: Open form from a SP form library

    I have created a form and have published it to a SharePoint form library. During the wizard, I was prompted to give it a name, and I observe the form library entry has the same name. Now, as a new user, when I use the link to access the form, my browser seems to be accessing a file called template.xsn, wheras my form is named "ExpenseSubmitter.xsn". Why did the form get published as template.xsn, and hence, my InfoPath program is unable to recognize and open this from the form library directly?

    A question I have about deployment is - is the InfoPath application needed directly on the client machine? I have an understading that forms can be submitted via SharePoint form pages that represent this form. But that is not my question. My situation is like this. Users in my company do not have InfoPath installed on their desktops. However, InfoPath can be made available as a Citrix published application. Can they use this Citrix published InfoPath program to open a form from a SharePoint portal site?

    I am depending on responses to understand the deployment requirements for an InfoPath form. Thanks!
  • 04-25-2005 03:48 AM In reply to

    Re: Open form from a SP form library

    Hi Ashwin Raj,
    I am answering to your first question here.
    When you are prompted to give a name, the name you enter will be the "Form Library" name at sharepoint site.
    When you are publishing a form to SharePoint, it picks up your InfoPath solution(".XSN") and stores it as template.xsn(It does not remember the existing name of your InfoPath solution.
    So When you click on "Fill Out a Form" at sharepoint, sharepoint site will open the template.xsn file in your form library. The Xml file that is generated when you save after filling the form will point to the 'template.xsn'(for ex.http://system/sites/ExpenseSubmitter/Forms/template.xsn) at your sharepoint site. You can see the href by opening .xml file in notepad.

    Hope this helps!


    Agni
    InfoPathDev India
  • 04-25-2005 06:25 AM In reply to

    Re: Open form from a SP form library

    Thank you very much for your reply, Agni. If the Publish-to-SharePoint-Site process typically saves the form as template.xsn on the site, how do I control this? This is preventing me from opening the form and using it by clicking on the Fill out a Form link on the SharePoint site.

    Can I control as what XSN file SharePoint saves it to? I am also curious as to what is the behavior when I try to publish multiple forms to SharePoint... would all the forms be saved as template.xsn?

    As part of the deployment process, I am trying to understand what are the best practice steps on publishing it to SharePoint and having users (with the InfoPath client) be able to access the form easily.
  • 04-25-2005 10:16 AM In reply to

    Re: Open form from a SP form library

    As far as I know you cannot control the process of Publishing to a sharepoint site.
    And there should not be an error if you click on fill out a form. Can you actually copy paste the error message that you see when you click on "Fill out a Form".

    Let me tell you in little more detail about publishing a form,
    When you publish a form to a sharepoint a "Library" is created where you can save the forms filled out by your users. And there will be a Template.XSN for each form library, which is specific to only this form library. You can actually find this Template.XSN Forms directory of your form library.

    When you publish multiple forms to sharepoint with different names then there will be multiple Form libraries with their own template.xsn. That means each form library has one template.xsn.


    Agni
    InfoPathDev India
  • 08-07-2006 11:30 AM In reply to

    Re: Open form from a SP form library

    One additional note on this thread. You CAN pass NewFromSolution an XML and InfoPath will still do the right thing! It's an undocumented feature! :)
    Shiraz Cupala / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
  • 03-17-2009 09:09 AM In reply to

    Re: Open form from a SP form library

    Hello Ashwin Raj

    did you find solution for your question - "Can they use this Citrix published InfoPath program to open a form from a SharePoint portal site?"..

    If so, please help to share. Thanks 

     

Page 1 of 1 (8 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.