473,473 Members | 1,745 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Display HTML in Application Window

Bob
I am pretty new at C#, so bare with me. I want to be able to read a local HTML file and display it in a browser window within my application. I also want to submit that page to my application and generate a "Post" to a web server and read the contents back and display back into the same browser window in my application

I have found the methods HttpWebRequest and HttpWebResponse that allows me to read/write to the Web server, but I am not sure which Class or methods I should use to render the HTML in my application window, or to display the HTML response

I am sure its fairly basic. Does someone have a code sample or link where they can direct me

Thanks for the hel

Nov 16 '05 #1
3 1924
Add a refernce to MSHTML. That has a browser component, so you end up
hosting "IE".

Then you can point it wherever you want, or write directly to the document.
You can even listen on localhost on whatever port, and have the webbrowser
component communicate to your app through that, if you are so inclined.

-mike
MVP

"Bob" <an*******@discussions.microsoft.com> wrote in message
news:7A**********************************@microsof t.com...
I am pretty new at C#, so bare with me. I want to be able to read a local
HTML file and display it in a browser window within my application. I also
want to submit that page to my application and generate a "Post" to a web
server and read the contents back and display back into the same browser
window in my application.

I have found the methods HttpWebRequest and HttpWebResponse that allows me
to read/write to the Web server, but I am not sure which Class or methods
I should use to render the HTML in my application window, or to display
the HTML response.

I am sure its fairly basic. Does someone have a code sample or link where
they can direct me.

Thanks for the help


Nov 16 '05 #2
Bob
Mike,
Thanks for the start, but can you give me a little more information, specifically which component ? I added the reference and see all kinds for things in there when I expand the Object List for MSHTML, but not sure where to start or which control method to begin with
Thank for you help
Bob
Nov 16 '05 #3
It'll create an ActiveX wrapper:

AxSHDocVw.AxWebBrowser

-mike
MVP

"Bob" <an*******@discussions.microsoft.com> wrote in message
news:4C**********************************@microsof t.com...
Mike,
Thanks for the start, but can you give me a little more information,
specifically which component ? I added the reference and see all kinds
for things in there when I expand the Object List for MSHTML, but not sure
where to start or which control method to begin with.
Thank for you help.
Bob


Nov 16 '05 #4

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

Similar topics

9
by: yezanxiong | last post by:
Hello all, I am new in asp.net developer,I would like to ask a simple question. how to display a message box in web application using asp.net? If I just use Private Sub btnOK_Click(ByVal...
3
by: Bob | last post by:
I am pretty new at C#, so bare with me. I want to be able to read a local HTML file and display it in a browser window within my application. I also want to submit that page to my application and...
7
by: TLM | last post by:
I am trying to build a web application that will contain links to files on a users local computer. I am assuming that the files will be in a known location and can display in a browser window. ...
8
by: lli | last post by:
Hi Guys, I have designed a web application. In its one window I put a form. User can click submit button of this form to run a pathon script to get data from database. Then User get a new window...
2
by: Patrick | last post by:
Hello, I need some advice on how to handle the following scenario in Javascript. Imagine an HTML page that displays relational database records from an address book application. Each record...
1
by: bigmaddaz | last post by:
Ok im designing an application for working out compount interest. The user starts the page, 3 prompts appear, one asking for money invested, next asking for rate of interest, and last one asking for...
9
by: tshad | last post by:
This was posted before but the message got messed up (all NLs were stripped out for some reason). I have 2 labels that hold the name of different images on my .aspx page. <asp:Label ID="Logo"...
14
by: lmttag | last post by:
Hello. We're developing an ASP.NET 2.0 (C#) application and we're trying to AJAX-enable it. We're having problem with a page not showing the page while a long-running process is executing. So,...
15
by: cssExp | last post by:
hello, Rather than going on a wild explanation on what's the the problem, it'll be much quicker and easier if i let you look at it yourself, so I'll post my page source (actual contents taken out,...
2
by: wreed06 | last post by:
Hello, I have 2 problems. In my webpage, I have a dropdown list with a button that takes the user to a popup window specific to the option. I am using Firefox 2.0.0.13. I have successfully...
0
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...
1
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...
0
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...
0
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,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
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...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
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 ...
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.