U
U
Uncle Bogdan2021-08-06 16:22:43
C++ / C#
Uncle Bogdan, 2021-08-06 16:22:43

Why does the FrameLoadEnd event fire only once?

Like I click on the button, I load the page, everything works and the method works.

private void button1_Click(object sender, EventArgs e)
        {
            browser.Load($"{url}{WebUtility.UrlEncode(textBox1.Text)}"); // Пример ссылки - https://kad.arbitr.ru/Card/4f2e853a-d214-4a0b-aa65-f2bfd5fc4dcc
        }


Then on the second button this code.

The page loads, but for some reason the method that the page is loaded does not work, although browser.Load () is there and there.

I'm not unsubscribing from the event anywhere. What's the catch?

string GoToPrintCardAddress = angle.QuerySelector("#b-case-header > ul.b-case-overview.g-ec > li.case-print > a").GetAttribute("href");
                browser.Load(GoToPrintCardAddress); // Срабатывает и переносит на другую страницу

// пример ссылки - https://kad.arbitr.ru/PrintCard/4f2e853a-d214-4a0b-aa65-f2bfd5fc4dcc

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question