Select links in Google Doc -
i'm looking following:
- locate links in document
- select them , change styling
so far, have:
var body = documentapp.getactivedocument().getbody(); var text = body.editastext().gettext(); var words = text.split(' '); (var = 0; < words.length; i++) { var word = words[i]; // doesn't work because word isn't text object // word.getlinkurl(); }
i understand how iterate on words in paragraph. issue determining if text link. can't use gettext()
method because converts text object string (prohibiting me testing if word link via getlinkurl()
method.
i've found number of "find , replace" solutions. can't use findtext()
because can't predict strings in links. instance, resources point example.com.
any appreciated.
this post seems you're looking for: get links
Comments
Post a Comment