Expand my Community achievements bar.

Submit HTTP without the HTTP button

Avatar

Level 1

I would like to submit my form data (LiveCycle Designer 8) using a button that both fires off the print action and the http submit action.

I have a button programmed to print (xfa.host.print(1, "1", (xfa.host.numPages -1).toString(), 0, 1, 0, 0, 0) but I can not figure out how to code the submit action for HTTP.

I have an HTTP submit button but I dont want the user to have to click two buttons.

Is there code (and what is it) to program the button to use the HTTP function of the HTTP button?

Thanks much,
Toph

1 Reply

Avatar

Level 10

You can achieve it the following way.

1) Place a HTTP Submit button on the form and set the Presence property to Hidden.

2) In the Print button you can make a call the Click event of the HTTP button, so it executes the click event code.

   

HTTPSubmitButton1.execEvent("click");

Hope this helps.

Thanks

Srini