Skip to content
This repository was archived by the owner on Dec 24, 2025. It is now read-only.
This repository was archived by the owner on Dec 24, 2025. It is now read-only.

How to change current URL to another URL #2

@sharkguto

Description

@sharkguto

When I try to change url in webview, I got the following error:

raise FletUnsupportedPlatformException(
flet.core.exceptions.FletUnsupportedPlatformException: This method is supported on Android, iOS and macOS platforms only.

Is it possible to change current URL to another one? for example:

chart_webview = fwv.WebView(
        url="about:blank",
        # url=chart_url,
        on_page_started=lambda _: page.eval_js(
            "console.log('Log do navegador: echarts iniciado!');"
        ),
        on_page_ended=lambda _: page.eval_js(
            "console.log('Log do navegador: echarts carregou!');"
        ),
        on_web_resource_error=lambda e: page.eval_js(
            f"console.log('Log do navegador: erro: {e.data}!');"
        ),
        expand=True,
    )

    chart_webview.height = 480  # altura fixa para o gráfico
# Função para carregar o gráfico 
def load_chart(chart_webview):
    encoded_html = load_chart_url()
    chart_webview.url = encoded_html

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions