I usually use Matlab's internal browser
(via, say, the 'web' command), but it has given me a problem by sometimes not detecting when the user clicks next on an online survey I administer through Matlab. I've never had that problem with any external browser (Firefox, Chrome, IE). I want to close the browser automatically when the user gets to the end of the survey. I know the URL that the user will go to after finishing the survey, so can see if the URL of their browser is the one they will be at after finishing the survey.
Right now using the internal Matlab browser, I use:
[s,bwser] = web(url2, '-new', '-notoolbar', '-noaddressbox');
cloc = get(bwser, 'currentLocation');
and then check if cloc is equal to the given URL. I would love to do the same thing with an external browser. I know how to call the external browser and assign it a URL. But how can I retrieve the current URL from that browser after the participant clicks on a link?