示例#1
0
        private static void ExecuteScroll(HtmlPreview htmlPreview, object scrollPercentage)
        {
            var javascript = string.Format("window.scrollTo(0,{0} * (document.body.scrollHeight - document.body.clientHeight));", scrollPercentage);

            htmlPreview.host.ExecuteScriptAsync(javascript);
        }
 private static void ExecuteScroll(HtmlPreview htmlPreview, object scrollPercentage)
 {
     var javascript = string.Format("window.scrollTo(0,{0} * (document.body.scrollHeight - document.body.clientHeight));", scrollPercentage);
     htmlPreview.host.ExecuteScriptAsync(javascript);
 }