Actually I think you can set the url for a submit button. Try using the following FormCalc code:
= user entered string
Kevin is right .....the Javascrit equivalent woudl be:
submitbuttonname.event_click.submit.target = URl string
1 person found this helpful
There should be two underlines in event__click. It's hard to see it in the forum posts.
Hey gays, thanks for answering.
However, looks like I still have problems.
When I insert a regluar HTTP submit button, it asks for the URL or it will give error.
Anyhow, if I leave the URL setting blank, and try to execute the code u mentioned, I get a messege, "submit canceled" and nothing is happening,
And if I enter something in the URL, looks like it still overites the code and submits the form the the hard coeded url.
In addition, the regular submit button does not even allow me to enter code in the click even, so I did enterend in the mose in even,
as to execute the code before the button is clicked.
In addition I also tried to enter the even in a text field exit which I was hoping to use so the user can enter their own url.
In other words.
could please be more specific.
On which even shown I enter the code.
in Form Calc
If I enter this on the mouse enter of the button:
form1.SCOPA_p2.HTTPSubmitButton1.event__click.#submit.#target = form1.SCOPA_p2.HTTPSubmitButton1_txt.rawValue;
I get error accessor form1.SCOPA_p2.HTTPSubmitButton1.event__click.#submit.#target is unknown
Any other thoughts
Check out the attached .pdf.
There is a textbox and an HTTP submit button on the form. Initially the button sets itself to hidden. For the text box, after you enter a URL, the exit event it sets the URL of the button to the entered text and makes the button visible. If you don't enter any text in the box the button will be made invisible again. There's no need to set a default URL for the button since it will not be enabled unless the user enters a URL.
Somewhere along the line I would add some code to valide the user's text; they must have "http://" in front, and it should end in ".something".
SetURL.pdf 78.0 K
Hi Guys, thank you very much for the help.
I fianlly made it work ))
Kevin. Thanks a loooooott for sending this file.
Just one think I want to clearify if someone else comes to this post looking for answer.
When I got Kevin's file, it was working perfectely, exactly what I needed. However, when I copied and pasted the text box and the button to my form, it was giving the same problems as before. I was just about to post my own file to you guys to see what is the problem, when I realized that I was saving my form as a [static pdf document].
So Of course, when I saved it as a [dinamic form] everithing is working now.
So the secert was there, I needed to save it as a dinamic document and NOT static.
Thank you all again