473,546 Members | 2,289 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Load HTML in WebBr from string

Hi,

Is there an alternative to an URI location when loading html into a
webBrowser control.

I have some html generated in a string. I would like to skip saving the
string to a file on disk and then loading it from disk into webbrowser with
its Navigate() method. Is there a direct (string -browser) method instead?.

Thanks.
Jesper, DK.

Aug 30 '06 #1
5 3066
Jesper,

You make me curious what are you doing.

wb.Navigate(http://windowssdk.msdn.microsoft.com...0x214wa.aspx);

This should be enough to show the page with the information about that.

I hope this helps,

Cor
"Jesper" <Je****@discuss ions.microsoft. comschreef in bericht
news:01******** *************** ***********@mic rosoft.com...
Hi,

Is there an alternative to an URI location when loading html into a
webBrowser control.

I have some html generated in a string. I would like to skip saving the
string to a file on disk and then loading it from disk into webbrowser
with
its Navigate() method. Is there a direct (string -browser) method
instead?.

Thanks.
Jesper, DK.

Aug 30 '06 #2
No, that didn't help.

Im building data output in html format like this

string src = "<html>.... ...</html>"

webBrowser.Load (src).

.... but no such functionality seems to exist. I have to save the string
first to disk and then load it into the browser using navigate... And I dont
want disk operations involved.

Any tips on how to avoid disk operations?

regards Jesper

"Cor Ligthert [MVP]" wrote:
Jesper,

You make me curious what are you doing.

wb.Navigate(http://windowssdk.msdn.microsoft.com...0x214wa.aspx);

This should be enough to show the page with the information about that.

I hope this helps,

Cor
"Jesper" <Je****@discuss ions.microsoft. comschreef in bericht
news:01******** *************** ***********@mic rosoft.com...
Hi,

Is there an alternative to an URI location when loading html into a
webBrowser control.

I have some html generated in a string. I would like to skip saving the
string to a file on disk and then loading it from disk into webbrowser
with
its Navigate() method. Is there a direct (string -browser) method
instead?.

Thanks.
Jesper, DK.


Aug 30 '06 #3
Jesper,

That functionality exist in the 2.0 webbrowser, I assume you talking about
that, because the old one has the name AxWebbrowser.

documenttext
http://msdn2.microsoft.com/en-us/lib...umenttext.aspx

I hope this helps,

Cor

"Jesper" <Je****@discuss ions.microsoft. comschreef in bericht
news:AD******** *************** ***********@mic rosoft.com...
No, that didn't help.

Im building data output in html format like this

string src = "<html>.... ...</html>"

webBrowser.Load (src).

... but no such functionality seems to exist. I have to save the string
first to disk and then load it into the browser using navigate... And I
dont
want disk operations involved.

Any tips on how to avoid disk operations?

regards Jesper

"Cor Ligthert [MVP]" wrote:
>Jesper,

You make me curious what are you doing.

wb.Navigate(http://windowssdk.msdn.microsoft.com...0x214wa.aspx);

This should be enough to show the page with the information about that.

I hope this helps,

Cor
"Jesper" <Je****@discuss ions.microsoft. comschreef in bericht
news:01******* *************** ************@mi crosoft.com...
Hi,

Is there an alternative to an URI location when loading html into a
webBrowser control.

I have some html generated in a string. I would like to skip saving the
string to a file on disk and then loading it from disk into webbrowser
with
its Navigate() method. Is there a direct (string -browser) method
instead?.

Thanks.
Jesper, DK.



Aug 30 '06 #4

Hi,

You can use webbrowser.docu mentText property to assign the html content
to webbrowser document. Also you can use streaming to load html.

Best Regards

Aug 30 '06 #5

Hi,

You can use webbrowser.docu mentText property to assign the html content
to webbrowser document. Also you can use streaming to load html.

Best Regards,
Erman OLCA

Aug 30 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
14065
by: rosty | last post by:
I am loading a page in the constructor of my form to the Microsoft Web Browser component: string URI = "http://some_address.org"; object flags = 0; object targetframe = ""; object headers = ""; object post = ""; this.axWebBrowser1.Navigate(URI, ref flags, ref targetframe, ref post, ref headers);
2
2481
by: Mark Kamoski | last post by:
Hi-- I need a code sample of how to redirect from an ASP.NET page to a frames-based html page and specifying what should load in the destination's frames. Any ideas? (Even air-code is much appreciated.)
1
1901
by: Biva | last post by:
Hello, I have a drop down list control in a datagrid. I can't seem to populate the control. Here is what my code looks like: <EditItemTemplate> <asp:DropDownList ID= "ddlUser5" DataSource = '<%# ddlUser5Bind() %>' Runat =server> </asp:DropDownList> </EditItemTemplate>
2
4984
by: Sam | last post by:
I have a custom control (MyTextBox - taken from Microsoft website) that implements the IPostBackDataHandler interface. It is added to the controls collection of a placeholder control during the Page Load of a main ASPX page. Now if we debug the MyTextBox, we find the order of events like so (during a Posback, of course): OnInit -> OnLoad ->...
26
2592
by: Niggy | last post by:
I am trying to load a file from a dropdownlist, however I get a error saying a virtual path is required. An example selected value would be "../4900/myfile.doc". Any ideas - my code is. Dim sumfin As String = DropDownList1.SelectedValue.ToString Dim pos As Integer = sumfin.Length Dim bString As String = sumfin.Substring(3, pos - 3) Dim...
12
4268
by: Dean Slindee | last post by:
My project has a main form (frmMain, the startup object for the project) and several other "child" forms that are painted within a large panel on frmMain. In each form's Form_Load event, a Weak Reference for that form is loaded into a global Hash table, like this: Dim wr As WeakReference = New WeakReference(Me, False) If Not...
2
2655
by: David Virgil Hobbs | last post by:
Loading text strings containing HTML code into an HTML parser in a Javascript/Jscript I would like to know, how one would go about loading a text string containing HTML code, so as to be able to use javascript or Jscript to work with the HTML code in the text string, in the same way that one works with XML code in a text string using the...
4
3397
by: Dick Sutton | last post by:
I am so close, yet oh so far! Here's the problem: I want to load a string variable that contains HTML into an instance of SHDocVw.InternetExplorer. Here's what I have so far: Function ShowMonTaxes(ByVal bTax As Boolean) As Integer Dim oIE As New SHDocVw.InternetExplorer ' set Internet Explorer properties... oIE.Left = 225 oIE.Top = 75
9
6336
by: =?Utf-8?B?VGhvbWFzIFcuIEJyb3du?= | last post by:
"parez" wrote: Assembly.LoadWithPartialName does indeed work!! Now, why is this incredibly useful routine deprecated and we are instructed to use Assembly.Load instead which does not provide the same functionality?!? I'll check now, but maybe someone knows... Is this deprecated routine still available in Visual Studio 2008 and .NET...
0
7435
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7947
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7461
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7792
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6026
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5360
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3491
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1921
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1046
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.