Is there a way to get HTMLview.Search to return something (bool or string) if the searched string is not found on the page?
In my code, I'm trying to find either one of two possible strings in the html files that I'm viewing. If the first is found, then I don't want to search for the second (and lose the first); but if the first is not found, then I do want to search for the second.
HTMLview.Search Return Something If Not Found
- airsoftsoftwair
- Posts: 5619
- Joined: Fri Feb 12, 2010 2:33 pm
- Location: Germany
- Contact:
Re: HTMLview.Search Return Something If Not Found
Currently not possible, but I'll see if this can be added.
- airsoftsoftwair
- Posts: 5619
- Joined: Fri Feb 12, 2010 2:33 pm
- Location: Germany
- Contact:
Re: HTMLview.Search Return Something If Not Found
Code: Select all
- New: HTMLview.Search() returns a boolean now indicating whether or not the search term was actually found
Re: HTMLview.Search Return Something If Not Found
Thanks, Andreas.
That will be very helpful.
That will be very helpful.
Re: HTMLview.Search Return Something If Not Found
found = moai.DoMethod(id, "Search", t$, flags$)
The result (found) seems always to report as False, even when the text has been found.
The result (found) seems always to report as False, even when the text has been found.
- airsoftsoftwair
- Posts: 5619
- Joined: Fri Feb 12, 2010 2:33 pm
- Location: Germany
- Contact:
Re: HTMLview.Search Return Something If Not Found
Ok, I'll check.
Re: HTMLview.Search Return Something If Not Found
I should have specified that I've only tried this on Android.