-
Content Count
39 -
Joined
-
Last visited
-
Days Won
4
Everything posted by salvadordf
-
Run the MiniBrowser demo and navigate to that web page. Then click on the top-right button and open the DevTools window. Switch to the Console tab, type your JavaScript code and press enter to read the error message : document.getElementById("linkRefresh").click(); The problem could be something as simple as a syntax error or that page could have multiple documents because it could have several frames. In any case, debugging the JavaScript code in the console tab is the best solution before calling WVBrowser.ExecuteScript
-
Is there a component can help me automate web actions ?
salvadordf replied to William23668's topic in VCL
Try using a CEF4Delphi browser in off-screen rendering (OSR) mode. That mode allows you to simulate mouse, touch and keyboard events. -
I'm not sure if it supports Delphi 6 but I would also try Wke4Delphi : https://gitee.com/LangjiApp/Wke4Delphi
-
I'm sorry but WebView4Delphi requires at least Delphi 7. If you need to test this component you can also use Lazarus or Delphi Community Edition.
-
It's not easy to use Chromium command line switches with TEdgeBrowser. Consider using WebView4Delphi instead and set GlobalWebView2Loader.AllowFileAccessFromFiles to true. You can also use the VirtualHostBrowser demo as a template for your application. It maps a local directory to a custom domain to load files from the hard drive.
-
Sorry for the shameless promotion but BriskBard allows you to set any proxy.
-
The WebView2 API doesn't have any interface to use custom proxy settings but you can use the Chromium command line switches. If you use TEdgeBrowser then you will have to create an ICoreWebView2EnvironmentOptions instance with those switches and pass it as a parameter in CreateCoreWebView2EnvironmentWithOptions. However, if you decide to use WebView4Delphi then all this is already implemented and you only have to set the GlobalWebView2Loader.ProxySettings properties. At this time, any WebView2 wrapper will only allow you to set the proxy settings once. If your application needs to change the proxy settings multiple times at run-time then you need to use CEF4Delphi.
-
I haven't checked that. Sometimes this is just the result of some temporal issue in the Google servers and they fix it but sometimes this a deliberate safety measure from Google against all embedded browsers. Try using a modern Firefox user agent string.
-
I've been asked to find a GUI automation tool for a Firemonkey desktop application for Windows. There're several tools that work for VCL applications but I can't find anything for FMX apps. Many well known tools can't find the FMX controls and they can only simulate mouse and keyboard events, compare screenshots, OCR, etc. All I could find is this StackOverflow question : https://stackoverflow.com/questions/30197921/how-can-i-automate-delphi-firemonkey-ui-testing-without-access-to-source-code That question has 2 suggestions : - Use the "FireMonkey Accessibility Package". - Build a "Test harness". The "FireMonkey Accessibility Package" for Delphi 10.2 is here : https://cc.embarcadero.com/Item/30780 It seems to work with Delphi 10.3 if we apply this fix : https://quality.embarcadero.com/browse/RSP-25532 My question to all of you is this : What GUI automation tool do you use for Firemonkey applications? Are we limited to building "Test harnesses" or using the "FireMonkey Accessibility Package"? Thanks!
-
CEF4DELPHI - How to get permisions to use Webcam and Microphone ?
salvadordf replied to Stéphane Wierzbicki's topic in Delphi Third-Party
Check these points : Assuming you use Windows 10, check if you can make that camera work with the "Camera" app. Install Chrome or Chromium 84. Ideally you should try to install 84.0.4147.89 and make the camera tests with the latest CEF4Delphi version from GitHub. Test your camera with Chrome/Chromium on webcamtoy.com. Open the SimpleBrowser2 demo and add GlobalCEFApp.EnableMediaStream := True; before the GlobalCEFApp.StartMainProcess call in the DPR file. Connect your camera, build the demo and test it in webcamtoy.com. If your camera works on a similar Chrome version then it should work with the SimpleBrowser2 demo or any other CEF application. -
CEF4DELPHI - How to get permisions to use Webcam and Microphone ?
salvadordf replied to Stéphane Wierzbicki's topic in Delphi Third-Party
After reading your code again I see that you're disabling the GlobalCEFApp.MultiThreadedMessageLoop property. It's recommended that Windows applications keep GlobalCEFApp.MultiThreadedMessageLoop enabled. Only in some cases you can consider disabling it but then you should use a "External Message Pump". -
CEF4DELPHI - How to get permisions to use Webcam and Microphone ?
salvadordf replied to Stéphane Wierzbicki's topic in Delphi Third-Party
Hi, I added GlobalCEFApp.EnableMediaStream := True; to the DPR file of the SimpleBrowser2 demo and I could see the video from my cheap webcam in webcamtoy.com About the registration issue, send me a PM with your username and I'll activate it manually. -
@Andrea Raimondi It would be used to test the whole application but they would like to be able to check every control property. I also asked this question in other places and it seems that all we have is mouse and keyboard events automation. Some tools like "Sikulix" also have OCR and image finding functions.