Hi again,
I'm encountering a search coding issue -
Using this post as inspiration, I'm adapting the code to my own needs:
http://acrobatusers.com/forum/forms-acrobat/homemade-search-field-questions
The code:
var Searchword = this.getField("Search").value;
search.bookmarks = "true";
search.wordMatching = "MatchAllWords";
search.query(Searchword, "ActiveDoc");
In that previous post, the issue was that when you run a search from a custom search field, it finds the "searchword" along with all the other returns. Therefor you have to manually skip the first instance of the searchword every time. Annoying.
The solution posted was embed an index (making sure all your fields are empty). When you run the search next time, it will look at the index and not the doc, bypassing your searchword altogether.
Doesn't seem like that's the case. I've done my index embedding, but I'm still getting a return on the "searchword." I also tried changing "activedoc" to "activeindexes" but that's a step backwards: It only exports your searchword to the search window and doesn't automatically run the search.
End goal here is to type in a word in our field, have it automatically search using acrobat's search tool (after pushing our custom search button to run the script), but bypassing all instances of the searchword field so it doesn't show.
Any idea on what I'm doing wrong?
D.
Thanks!
D.