twebbrowser

Spell checker in TWebBrowser (TEmbeddedWB) control

随声附和 提交于 2019-12-07 14:47:28
问题 Internet Explorer 10 has built in spell checker and it works just fine. I tried to create a small HTML page to test it with following contents: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML lang=en xml:lang="en" xmlns="http://www.w3.org/1999/xhtml"><HEAD> <META name=GENERATOR content="MSHTML 10.00.9200.16721"></HEAD> <BODY spellcheck=true contentEditable=true style="MARGIN: 0.5em"> <P>Theze ara mispeled wordz</P> </BODY></HTML> All that is needed is to put properties

How to debug division by zero exception in Internet Explorer?

好久不见. 提交于 2019-12-06 19:25:30
问题 i am hosting Internet Explorer in a Windows application. i can scroll down to the bottom of the document. When i then try to scroll back up i get a division by zero exception : When i scroll using Page Up the crash appears to happen at the call to - IOleInPlaceActiveObject:TranslateAccelerator When i scroll using the mouse the crash happens during the call to DispatchMessage Either way, the crash is happening in Internet Explorer. The stack trace shown by Delphi at the time of the exception:

TWebBrowser modal print dialog?

心不动则不痛 提交于 2019-12-06 15:13:06
I've found many ways to make the TWebBrowser show a modeless print dialog box, but how do I make it show a modal one? I would like to print an html page, that's why I need the modal dialog. I'd really appreciate your ideas on this one. Thanks! I cannot think of a reason why there would be lots of ways to show a modeless dialog. Why would you want to continue interacting with the web browser while a modeless print dialog is displayed? If you want to initiate the print by program, but need the user to select the printer, use: ExecWB(OLE_CMDID_PRINT, OLECMDEXECOPT_PROMPTUSER); Eureka! I solved it

How can I avoid refresh with TWebBrowser

社会主义新天地 提交于 2019-12-06 12:45:58
问题 I have a TWebBrowser component that show a Google maps page. The problem is that when user press F5 the page refresh and page reloads. This cause javascript variables to reinitialize and get out of sync with Delphi and a scripting error dialog appear, 'undefined' is null or not an object. I want to stop refresh from the user. I tried this event for OnBeforeNavigate2: procedure TNewOrganizationForm.mapAddressBeforeNavigate2(ASender: TObject; const pDisp: IDispatch; var URL, Flags,

Delphi TChromium / DCEF3 - Constant Access Violations

人盡茶涼 提交于 2019-12-06 12:37:27
问题 I'm trying to use DCEF3 TChromium as a replacement for TWebbrowser component. I downloaded the packages and installed it on my IDE (Delphi 2007). I'm testing the demo on demos\guiclient and when i try to open certain web pages, i get tons of Access Violation exceptions and my app crashes. If i'm inside Delphi, i get this exception before Delphi itself crashes : 'Assertion failure : 'item.src' in \win32scr\DBKIMPL.CPP' at line 2691' One example of a page that has this problem is www

disable dialog webbrowser delphi

隐身守侯 提交于 2019-12-06 08:35:18
how to prevent the appearance of the dialog box This document has changed. save changes? which occurs in the transition when webbrowser about: blank Thank you so much. did so Browser.Navigate ('about: blank'); DesignMode (false ,''); Browser.OnNavigateComplete2: = NavigateComplite; procedure NavigateComplite (ASender: TObject; const pDisp: IDispatch; var URL: OleVariant); begin DesignMode (true ,''); end; i think wich you are using the designMode property from the IHTMLDocument2 Interface in your code. you can disable the dialog box setting this property to 'Off'. try this code before to

How can I add an extra http header using IHTTPNegotiate?

混江龙づ霸主 提交于 2019-12-06 05:11:30
问题 How can I add an extra header to the request using IHTTPNegotiate? I added the interface but functions BeginningTransaction & OnResponse never get called. TNameSpaceHandler = class(TComObject, IInternetProtocol, IHttpNegotiate) ... function BeginningTransaction(szURL, szHeaders: LPCWSTR; dwReserved: DWORD; out szAdditionalHeaders: LPWSTR): HResult; stdcall; function OnResponse(dwResponseCode: DWORD; szResponseHeaders, szRequestHeaders: LPCWSTR; out szAdditionalRequestHeaders: LPWSTR): HResult

Creating TWebBrowser in Runtime with Delphi

别等时光非礼了梦想. 提交于 2019-12-06 03:34:37
问题 I have a TWebBrowser object which is created in runtime and used in background, that is, not visible. The problem is that events like OnDocumentComplete dont work or are not triggered in Delphi2009. Any advice? procedure TfrmMain.FormCreate(Sender: TObject); begin FWebBrowser:= TWebBrowser.Create(Self); FWebBrowser.RegisterAsBrowser:= True; FWebBrowser.OnDocumentComplete:= WhenDocIsCompleted; end; procedure TfrmMain.WhenDocIsCompleted(ASender: TObject; const pDisp: IDispatch; var URL:

How to debug division by zero exception in Internet Explorer?

倾然丶 夕夏残阳落幕 提交于 2019-12-05 01:14:43
i am hosting Internet Explorer in a Windows application. i can scroll down to the bottom of the document. When i then try to scroll back up i get a division by zero exception : When i scroll using Page Up the crash appears to happen at the call to - IOleInPlaceActiveObject:TranslateAccelerator When i scroll using the mouse the crash happens during the call to DispatchMessage Either way, the crash is happening in Internet Explorer. The stack trace shown by Delphi at the time of the exception: Is different from the stack trace shown by Jedi's exception tracing: Exception EZeroDivide in module

How can I avoid refresh with TWebBrowser

情到浓时终转凉″ 提交于 2019-12-04 19:09:45
I have a TWebBrowser component that show a Google maps page. The problem is that when user press F5 the page refresh and page reloads. This cause javascript variables to reinitialize and get out of sync with Delphi and a scripting error dialog appear, 'undefined' is null or not an object. I want to stop refresh from the user. I tried this event for OnBeforeNavigate2: procedure TNewOrganizationForm.mapAddressBeforeNavigate2(ASender: TObject; const pDisp: IDispatch; var URL, Flags, TargetFrameName, PostData, Headers: OleVariant; var Cancel: WordBool); begin inherited; Cancel := Assigned