WPF : download files through CefSharp

↘锁芯ラ 提交于 2020-01-15 05:42:33

问题


I'm using CefSharp 1 in my wpf app. How can I download files from sites through my embedded navigator ? When I click on a download link, nothing happens.


回答1:


See answer in this thread in the CefSharp group




回答2:


You may need to add a shceme handler for the 'file' protocol. That's what we did...

Register a scheme with CEF -

CEF.RegisterScheme("file", new HandlerFactory());

Add a scheme handler that loads the file from disk and returns a relevant response



来源:https://stackoverflow.com/questions/22456249/wpf-download-files-through-cefsharp

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!