Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > General Discussion
  New Posts New Posts RSS Feed - .InnerHTML limited to 255 chrs
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

.InnerHTML limited to 255 chrs

 Post Reply Post Reply
Author
Message
PPL1 View Drop Down
Groupie
Groupie


Joined: 10 April 2006
Location: Canada
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote PPL1 Quote  Post ReplyReply Direct Link To This Post Topic: .InnerHTML limited to 255 chrs
    Posted: 17 March 2008 at 12:40pm
In the ActiveX Suite, the WebBrowser control InnerHTML property is limited to 255 chrs. I hope this will be fixed soon...
 
Are there any workarounds using ExecWB or something else ?
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 17 March 2008 at 1:41pm
Hi,
Just tried 350 chars - works without problems.
Can you show html/code you tried ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
PPL1 View Drop Down
Groupie
Groupie


Joined: 10 April 2006
Location: Canada
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote PPL1 Quote  Post ReplyReply Direct Link To This Post Posted: 17 March 2008 at 1:55pm
This VB code works:
  s = "Web site : <a href=""http://www.sqlnotes.net"" target=""_blank"" Title=""www.SQLNotes.nethttp://www.sqlnotes.net"">www.SQLNotes.net</a> &nbsp; &nbsp; "
  s = s & "<a href=""http://www.sqlnotes.net/Forums/tabid/54/Default.aspx"" target=""_blank"">Forums</a> "
  Me.txtWebSite.innerHTML = s
But this does not:
  s = "Web site and more text to show if there is a problem : <a href=""http://www.sqlnotes.net"" target=""_blank"" Title=""www.SQLNotes.nethttp://www.sqlnotes.net"">www.SQLNotes.net</a> &nbsp; &nbsp; "
  s = s & "<a href=""http://www.sqlnotes.net/Forums/tabid/54/Default.aspx"" target=""_blank""  Title=""Forumshttp://www.sqlnotes.net"">Forums</a> "
  Me.txtWebSite.innerHTML = s
I use the Unicode versions
 
In text mode, this does not work:
Web site and more text to show if there is a problem : <a href="http://www.sqlnotes.net" target="_blank" Title="www.SQLNotes.nethttp://www.sqlnotes.net">www.SQLNotes.net</a> &nbsp; &nbsp; <a href="http://www.sqlnotes.net/Forums/tabid/54/Default.aspx" target="_blank"  Title="Forumshttp://www.sqlnotes.net">Forums</a>
 
But making the first text shorter works. I've tested and it stops working after exactly 259 chrs
 
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 18 March 2008 at 5:57am

Hi,

Again Both work with ANSI and Unicode.

Here sample project: WebBrowser.zip

 
Maybe it depends on IE version... Please check if attachment works for you.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
PPL1 View Drop Down
Groupie
Groupie


Joined: 10 April 2006
Location: Canada
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote PPL1 Quote  Post ReplyReply Direct Link To This Post Posted: 18 March 2008 at 9:12am
I tried your sample and it displays blank in the top one and "Page cannot be displayed" in the bottom.
I use IE 6 Win XP SP2 all updates applied
Using ActiveX .Unicode.v11.2.2
Back to Top
nighthawk View Drop Down
Senior Member
Senior Member
Avatar

Joined: 11 June 2004
Status: Offline
Points: 167
Post Options Post Options   Thanks (0) Thanks(0)   Quote nighthawk Quote  Post ReplyReply Direct Link To This Post Posted: 18 March 2008 at 6:42pm
I noticed the same limit of only displaying around 250 characters.  Thanks for bringing this up.  I am getting the same results on Oleg's sample project (blank top and "Page cannot be displayed" on bottom).  I am also using IE 6 with Win XP SP2.
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 20 March 2008 at 12:59am
Hi,
 
I tried the sample with IE7 and it works.
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 20 March 2008 at 2:33am
Hello,
 
Thanks, it indeed depends on IE version :( We fixed it for 12.0 release.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
PPL1 View Drop Down
Groupie
Groupie


Joined: 10 April 2006
Location: Canada
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote PPL1 Quote  Post ReplyReply Direct Link To This Post Posted: 20 March 2008 at 11:19am

OK.

Going back to my original post, is there a workaround ? (using ExecWB or a link to the DOM ?)
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 20 March 2008 at 12:05pm
Hi,
 
try this as workaround
 
Private Sub Form_Load()
WebBrowser1.Navigate "about:blank"
End Sub
Private Sub WebBrowser1_DownloadComplete()
s = "Web site and more text to show if there is a problem : <a href=""http://www.sqlnotes.net"" target=""_blank"" Title=""www.SQLNotes.netwww.SQLNotes.nethttp://www.sqlnotes.net"">www.SQLNotes.net</a> &nbsp; &nbsp; "
 s = s & "<a href=""http://www.sqlnotes.net/Forums/tabid/54/Default.aspx"" target=""_blank""  Title=""Forumshttp://www.sqlnotes.net"">Forums</a> "
 
 
 WebBrowser1.Document.Body.InnerHTML = s
 
End Sub
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
PPL1 View Drop Down
Groupie
Groupie


Joined: 10 April 2006
Location: Canada
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote PPL1 Quote  Post ReplyReply Direct Link To This Post Posted: 21 March 2008 at 6:46pm
That works fine.
 
When loading many different strings however, I'll need to use some global variable to track which string to load. Not ideal but workable
 
Thanks
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.281 seconds.