bsalsa - Delphi tips, tricks, code snippets,Samples Component Search Engine.

The current search engine database includes about 5000 Delphi web sites and growing...

By pressing the button, you can add the Search engine to your iGoogle. Add to Google


Go Back   EmbeddedWB - bsalsa forum > TEmbeddedWB component > TEmbeddedWB Component
FAQDonate Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 11-10-2009, 06:21 PM   #1
Alfred
Junior Member
 
Join Date: Oct 2008
Posts: 28
OnDocumentComplete

Why does TEmbeddedWB fire an OndocumentComplete upon startup without anything loaded ?

If I have a form with just the TEmbeddedWB on it, it fires an OnDocumentComplete when starting the application.

Now when I want to load a local file it fires the event twice, giving me errors because during the first event firing the file isn't actually loaded, only during the second event firing....

Can't put my finger on this....

[Edit]
I just checked, but TWebBrowser does not have this behaviour..

Last edited by Alfred; 11-10-2009 at 08:42 PM. Reason: typo
Alfred is offline   Reply With Quote
Old 11-10-2009, 07:31 PM   #2
Rafs
Junior Member
 
Join Date: Nov 2008
Posts: 14
I have the same behaviour with the latest build. Seems like the TEmbeddedWb autonavigate to about:blank during creation.
Rafs is offline   Reply With Quote
Old 11-10-2009, 08:43 PM   #3
Alfred
Junior Member
 
Join Date: Oct 2008
Posts: 28
Yeah, my program was suddenly broken...
Can't remember any problems with previous builds either.
Alfred is offline   Reply With Quote
Old 11-12-2009, 11:21 AM   #4
smot
Main Developer
 
smot's Avatar
 
Join Date: May 2006
Posts: 937
1. Open EmbeddedWB.pas

2. Go to

Code:
 
procedure TEmbeddedWB.HTMLCodeChanged(Sender: TObject);
3. Replace

Code:
 
      LoadFromStrings(HTMLCode);
with

Code:
 
      if HTMLCode.Count <> 0 then
        LoadFromStrings(HTMLCode);
Hope that helps
smot is offline   Reply With Quote
Old 11-13-2009, 01:59 PM   #5
Alfred
Junior Member
 
Join Date: Oct 2008
Posts: 28
yes, that does the trick...
Thanks
Alfred is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT +3. The time now is 08:25 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
bsalsa@gmail.com