Relative Content

Tag Archive for c#winformswebview2

Drag-dropping files into WebView2

I´ve got a WinForms App where a form contains a WebView2 component as big as the form itself. The code below works fine on the form itself, since the WebView2 element lays on top of the form I´m not able to use the drag-drop functionality on the form and I have to use the WebView2´s one. But it doesnt work the way stated below.

How to restrict WebView2 from downloading content?

I have a WinForms2 C# application with a basic WebView2 component along with a textBox (to be used as a search bar). I want to restrict the webView2 from being able to download content. For example, if I go to pixabay.com and try to download an image, I want it to stop the download and restrict that image from being downloaded.

How can I jump automatically to the next PDF-page by using corewebview2 in WinForm

I did a WinForm application to view PDF files. I use WebView2 of Microsoft and CoreWebView2.Navigate(pdfFile). The PDF – file ist displayed fine, but I have problems if the PDF file has several pages. It shows me the first page and I get scrollbars to go manually to the next pages which works fine too. But I need to diplay one page after the other automatically. Let’s say always after 30 seconds I must display the next page. Until now I didn’t find a way to do it. I hope that here is someone who knows how to do it!
What is also disturbing me that I see scrollbars, if it’s a multipage PDF-file.