How do I execute a function once a google form is finished inside a webview? - swift

I am using Google Forms in my swift app. The user is supposed to click a button, and then go into a webview to complete the form. The problem is that, once the user completes the form, they are stuck on the finish page. I don't want to add a navigation controller in my app because the user would then be able to skip the form. I am having issues finding ways to make a function that is executed once the form is finished. Any help would be appreciated.

I found way to workaround the issue by providing a link at the end of the google form to finish the form. The webview would then recognize the changed url.

Related

callback function after Google Form is submitted

Hi I am embedding a Google Forms in a website, through .
I want to add a callback function to the form, so that I can now that the user submitted it, and I can close the form window (or display a button to close it).
How to do it?
I have not found such a function in GDoc Form. I saw there is a script editor, but could not make it work for me, seems overkill.
I was adding a button to my html page that is always displayed atop of the form, but actually I would like it to appear only after the user completed the form.
--
Edited
Tried iFrame src change event detection?
but still I undergo
Uncaught DOMException: Blocked a frame with origin

Google Forms Onclick Submit

I have created a simple Google Form with two multiple choice answers (Yes and No). Image below.
The form works fine when I select an answer then click the submit button.
I'm wondering if it's possible to submit the form immediately when an option is selected? Then refresh the page.
I've been reading about triggers here but not sure where to start, or if it's even possible.
Google Forms is my only option at current, I know this is possible via other methods.
Any advice is appreciated.
I'm wondering if it's possible to submit the form immediately when an option is selected? Then refresh the page.
No, it's not possible. The only trigger that works on the form respondent view is on form submit.
The workaround is to create your own form. If you want to work with Google Apps Script, you should use the HTML Service.

Fancybox 2: Any way of opening iframe without showing it?

I am using Fancybox 2 for my web application. I read its online documenation, but failed to find a way of opening iframe without showing it to a user.
The reason for my inquiry is that when a regular page is loaded, I would like to make a Fancybox iframe get loaded too without a user's notice. When the user clicks on a link on the page that will trigger Fancybox to show the iframe, I would like to make it simply visible. I hope this would greatly improve user experience in terms of speed.
Any ideas or links would be really appreciated.
You could, for example, simply create hidden iframe element and display it as any other "inline" element using fancyBox.

How can i have webdriver refresh but submit form data every refresh?

So essentially driver.refresh() does not submit form data for example a captcha on the page. If you refresh in a browser, a pop-up appears saying confirm form resubmission if you click continue the browser submits the form data and you don't have to solve the captcha again. Is there any way that I can automate selenium to confirm the form resubmission every driver.refresh() ?
Assuming this is an alert, which is what it appears to be, you simply add this line of code after you call for the driver to refresh.
driver.switchTo().alert().accept();
Yes, you could write a Custom driver class, which extends the selenium driver class you are using, and overwrite the refresh method(or make your own). But, that would be bad practice.
Since not all pages you automate against will have form data.

How to update the responses of the google form to the form itself

I am creating a Google Form. I want to insert a count in the end(anywhere,not specific) of the form which will show the number of responses submit till date.This goes like updating the live count. I have tried using script editor for Google Form Add-ons option.But I am unable to view the results automatically or changes. It asks me to accept "Terms of Service" which I don't want to do right now because I am not sure about the way it may result.
There are various options available to view the form results/responses.But here I don't want to view the results later.They should get updated when we click the submit button on form.Please note..simultaneously many users may fill the form.
To implement this,I have thought of logic like whenever submit button gets clicked..the text in the form should get updated.
Please suggest how I can add the count or apply above logic of whenever submit operation is performed. Is it possible?? Any other suggestions are welcomed..Thanks in Advance!!!
I found another possible way of doing this..I received all the responses in Google Spreadsheet..which I later embedded in my site. Solves the purpose..And the embedded data gets updated automatically for the responses !! Cheers