Micro conversion from TEmbeddedWB to TChromiumWindow (Delphi)
₹600-1500 INR
Pågår
Lagt ut over 4 år siden
₹600-1500 INR
Betalt ved levering
The project is just to tell me which properties I should use to migrate from TEmbeddedWB to TChromiumWindow.
Only in the properties / functions below: TEmbeddedWB -> TChromiumWindow
1 - [login to view URL]
--------------------------------------------------------
2 - ShowMessage([login to view URL]('field', 0).value);
--------------------------------------------------------
4 - [login to view URL]
--------------------------------------------------------
5 - [login to view URL]
--------------------------------------------------------
6 - [login to view URL]
--------------------------------------------------------
procedure WebBrowserFileDownload(Sender: TCustomEmbeddedWB; pmk: IMoniker;
pbc: IBindCtx; dwBindVerb, grfBINDF: Cardinal; pBindInfo: PBindInfo;
pszHeaders, pszRedir: PWideChar; uiCP: Cardinal; var Rezult: HRESULT);
In this event, it is possible to get the file link that the browser would download, but without displaying the download information on the screen.
The link is in the "pszRedir" variable.
You can not display the download information by changing the variable: Rezult: = S_FALSE;
--------------------------------------------------------
[login to view URL]
--------------------------------------------------------
In this section, I modify an existing alert script not to be displayed in the browser as follows.
var document:IHTMLDocument2;novoScript:IHTMLDOMNode;
begin
document := [login to view URL] as IHTMLDocument2;
if Assigned(document) then
begin
novoScript := [login to view URL]('script') as IHTMLDOMNode;
(novoScript as IHTMLScriptElement).text := 'function alert(s){}';
([login to view URL] as IHTMLDOMNode).appendChild(novoScript);
end;
end
--------------------------------------------------------
In this part, I prevent the "confirm" message from being displayed.
html
<input type="submit" name="button" value="informacao" onclick="return confirm(mensagem);" id="button" class="botao" />
[login to view URL]('button', 0).onclick:='true';
-----
Only that.