Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem reopening WebUI Window from desktop app after user closes it voluntarily #4

Open
Olray opened this issue Jul 16, 2024 · 1 comment

Comments

@Olray
Copy link

Olray commented Jul 16, 2024

I'm trying to use WebUI4Delphi to serve html documents from a database with about 60k documents. The wrapper is straightforward and easy to use. It also works as good as I ever hoped for, but... The special case is: I'm using a desktop app for selecting the documents and call Show() with a virtual URL that is going to be served from inside the filehandler.

When the user choses to close the WebUI window and selects another document afterwards, the window (with same ID as the window_id from previous calls) is reopened for a second and closes itself half a second later. The file handler is called with the new "virtual url" and then the app comes to a halt for about 10 seconds. No events are dispatched to my OnWebUIEvent function anymore.

Is there anything I have to do to "fix" the Window object after the user closes the window manually? And how do I find out if the Window object is in such state?

@salvadordf
Copy link
Owner

Hi,

The HTML in all windows must load the webui.js script to communicate with your application.

Try the new web_app_multi_client demo. It allows you to have multiple connections and clients.

The current WebUI4Delphi version uses a beta WebUI library and it may have bugs. If you find one please provide a small demo to replicate the issue in my computer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants