Window forms in InfoPath - InfoPath Dev
in

InfoPath Dev

Window forms in InfoPath

Last post 03-07-2006 08:36 PM by vasanthaprabu. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 03-06-2006 06:38 AM

    Window forms in InfoPath

    Dear Friends,

    I would like to add one control in the InfoPath which is not in the InfoPath Controls that FileDialog.

    Thats I need a file path of a file.. now I am just manual enter the file path instead of that I want to add FileOpenDialog box to browse the file and then get the file path ... Is it possible in infopath.

    I have try with File Attachment, but I cant get the File path... if I got the file path I will send it to my webservice and then get the result from the webservice.

    My only problem is How can I get the file path of a file in the infopath form using controls.

    Thanks in Advance.

    Regards,
    Vasanth.
  • 03-06-2006 10:48 AM In reply to

    Re: Window forms in InfoPath

    Hi Vasanth,
    You can add a File dialog control(HTML) to your task pane and ask user to click on the button to open the file dialog and select the File URL. You can pass this value to the Webservice and then get the result from the webservice.
  • 03-06-2006 08:12 PM In reply to

    Re: Window forms in InfoPath

    Hi Agni,

    Thank you very much.
    Can you give me some example about the TaskPane...or any links. I am using InfoPath .NET Toolkit for developing.

    Regards,
    Vasanth.
  • 03-06-2006 10:38 PM In reply to

    Re: Window forms in InfoPath

    Hi Vasanth,
    1. First create a HTML page with "File" control.
    2. Add this HTML page as Resource file.
    3. Go to "Tools->FormOptions->Advanced->Select 'Enable Custom Taskpane'
    4. Select your HTML page in the dropdown.
    5. Click ok.

    You can get reference to the XDocument in the taskpane with the following line of code
    "window.external.Window.XDocument;"

  • 03-06-2006 11:23 PM In reply to

    Re: Window forms in InfoPath

    quote:
    Originally posted by Agni

    Hi Vasanth,
    1. First create a HTML page with "File" control.
    2. Add this HTML page as Resource file.
    3. Go to "Tools->FormOptions->Advanced->Select 'Enable Custom Taskpane'
    4. Select your HTML page in the dropdown.
    5. Click ok.

    You can get reference to the XDocument in the taskpane with the following line of code
    "window.external.Window.XDocument;"





    Thank you Agni,

    Regards,
    Vasanth.
  • 03-07-2006 08:36 PM In reply to

    Re: Window forms in InfoPath

    Hi Agni,

    Thanks for your idea!.......

    Here is the Code!,

    HTMLTaskPane htmlTaskPane = (HTMLTaskPane) thisXDocument.View.Window.TaskPanes[0];
    HTMLDocument htmlDoc = (HTMLDocument) htmlTaskPane.HTMLDocument;
    IHTMLElement elmnt = htmlDoc.getElementById("F1");
    txtFields.text = elmnt.getAttribute("value",0).ToString();

    Thank you Agni,(You can trigger me if you have any other idea).

    But I have one doubt that What the use of developing Infopath in .NET ToolKit...I have little bit confuse. Can you clear me.

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