C# How to get cookies from GeckoWebBrowser control

前端 未结 2 791
广开言路
广开言路 2021-01-20 15:30

I am using the GeckoWebBrowser control for navigate an URL. It actually should have cookies when that page is loaded. But if I tried to get the cookie, I get a blank text ev

2条回答
  •  没有蜡笔的小新
    2021-01-20 16:23

    i found a reason for this issue, because the all element of geckowebbrowser is loading then you set cookie immediately, so geckowebbrowser not enough time to authorized. My solution is make a button. onload winform you do navigate url you wan, after than you click on button, behind event button you set authorized cookie for your url. It's working for me. :)

提交回复
热议问题