I've tried this code, but it does not seem to work:
- Code: Select all
// this _should_ scroll to the top of the HTML editor
strJS:= Format('$($("#%s").find("iframe")[0].contentDocument.body).scrollTop(0);',[Self.htmleditorEmailBody.Name]);
WebApplication.CallBackResponse.AddJavaScriptToExecute(strJS);
I have also tried using .HTMLName, to no avail:
- Code: Select all
// this _should_ scroll to the top of the HTML editor
strJS:= Format('$($("#%s").find("iframe")[0].contentDocument.body).scrollTop(0);',[Self.htmleditorEmailBody.HTMLName]);
WebApplication.CallBackResponse.AddJavaScriptToExecute(strJS);
This is the value of strJS:
- Code: Select all
$($("#HTMLEDITOREMAILBODYCOMPONENT_FAD6E7B9").find("iframe")[0].contentDocument.body).scrollTop(0);
I'm definitely not a JS guru... anyone care to weigh in?
Thanks,
Scott