473,626 Members | 3,276 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

DHTML editor with AxWebBrowser

Hi all,

I try to make a DHTML editor in C#. I arrive to modify a web page. Now
I want to add picture but i don't arrive to find good documentation or
sample on the web.

Here is my source code :
private void frmEdit_Load(ob ject sender, System.EventArg s e)
{
object missing = System.Reflecti on.Missing.Valu e;
object path = Directory.GetCu rrentDirectory( ) + "\\test.htm ";
mshtml.HTMLDocu mentClass doc;
this.axWebBrows er1.Navigate2(r ef path, ref missing, ref missing, ref
missing, ref missing);
doc = (mshtml.HTMLDoc umentClass)this .axWebBrowser1. Document;
doc.designMode = "On";
}

I want to add a button to insert an image where the cursor is.

Can you help me please ?

TIA

D

Jun 28 '06 #1
2 1744
You can use the Image control:
http://msdn2.microsoft.com/en-us/lib...77(d=ide).aspx

chanmm

<da**@caramail. com> wrote in message
news:11******** *************@x 69g2000cwx.goog legroups.com...
Hi all,

I try to make a DHTML editor in C#. I arrive to modify a web page. Now
I want to add picture but i don't arrive to find good documentation or
sample on the web.

Here is my source code :
private void frmEdit_Load(ob ject sender, System.EventArg s e)
{
object missing = System.Reflecti on.Missing.Valu e;
object path = Directory.GetCu rrentDirectory( ) + "\\test.htm ";
mshtml.HTMLDocu mentClass doc;
this.axWebBrows er1.Navigate2(r ef path, ref missing, ref missing, ref
missing, ref missing);
doc = (mshtml.HTMLDoc umentClass)this .axWebBrowser1. Document;
doc.designMode = "On";
}

I want to add a button to insert an image where the cursor is.

Can you help me please ?

TIA

D

Jun 28 '06 #2
Thanks, but I use a winform. So the image control dosn't work.

chanmm a écrit :
You can use the Image control:
http://msdn2.microsoft.com/en-us/lib...77(d=ide).aspx

chanmm

<da**@caramail. com> wrote in message
news:11******** *************@x 69g2000cwx.goog legroups.com...
Hi all,

I try to make a DHTML editor in C#. I arrive to modify a web page. Now
I want to add picture but i don't arrive to find good documentation or
sample on the web.

Here is my source code :
private void frmEdit_Load(ob ject sender, System.EventArg s e)
{
object missing = System.Reflecti on.Missing.Valu e;
object path = Directory.GetCu rrentDirectory( ) + "\\test.htm ";
mshtml.HTMLDocu mentClass doc;
this.axWebBrows er1.Navigate2(r ef path, ref missing, ref missing, ref
missing, ref missing);
doc = (mshtml.HTMLDoc umentClass)this .axWebBrowser1. Document;
doc.designMode = "On";
}

I want to add a button to insert an image where the cursor is.

Can you help me please ?

TIA

D


Jun 28 '06 #3

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

Similar topics

0
1419
by: Jose Ricardos | last post by:
I'm creating a web site where I want my users to be able to edit articles using a WYSIWYG editor on the web page itself. Ideally they should be able to use headings, bold, upload images and include them and include links too. Also it should be possible to include an 'article' (in a box) inside another article. I know I might have to code this myself so I'd like the editor to be DHTML and ideally open-source or customizable. Where...
4
4793
by: TF | last post by:
hi, i am using AxWebBrowser control in my C# dot.net windows application. i want to display a web page in the browser that needs some data sent to it through HTML Form 'POST' method. I saw a method 'Navigate' of AxWebBrowser control that has a parameter 'ref object postData' but didn't find any documentation about AxWebBrowser how to use it. i tried a string like "name1=value1&name2=value2" but it doesn't work. Any help?? Thanks
4
3779
by: Martin Ho | last post by:
Hey Everyone, I really hope there is someone who can figure out this problem. Honestly, I spent 3 days now trying to find the solution, but nothing works. I'll try to explain the problem shortly, so I don't take too much of your time. Problem:
0
2907
by: Matthias Kwiedor | last post by:
I have a aplication which hosts an axWebbrowser. This activex component needs about 10 to 15 mb of memory. Because i have a option to move the aplication to tray icon and do some timer work i don't want that it just spends over 10mb for nothing. So i remove the axwebbrowser with axwebbrowser1.dispose() which works fine. After show the application back from the tray icon i will implement the axwebbrowser again with the same i did it...
3
10202
by: Clint MacDonald | last post by:
I have used the AxWebBrowser in a Visual Basic Project... I found that both Framework 1.0 and 1.1 had to be installed for it to work properly. I now have found that in Studio 2003, that the probablem has come back even if both are installed. When I open a windows form that has the Browser on it and try to Navigate to a page using the OnEnter or OnLoad events, the page just sits there and does
7
2860
by: Mike | last post by:
Hello, I am developing a simple web editor to enable my users to update their websites and add simple formatting to the text. The page content is recovered from a SQL Server database and displayed in the Microsoft DHTML Edit control ( I am working in Visual Studio 2003 - VB ). I have experimented with the ExecCommand function but all I want to do is select some text - press a button to make that selected text <h1>some text</h1>. I have a...
6
3762
by: Dave Booker | last post by:
It appears that I cannot correctly install the AxWebBrowser in VS2005. I can instantiate an "AxWebBrowser browser" and refer to its members, properties, and methods. I'm having trouble with the AxWebBrowser.Document: When I print browser.Document.GetType().ToString() at runtime, I get "mshtml.HTMLDocumentClass". But The VS2005 compiler does not recognize the member AxWebBrowser.Document as anything other than a System.Object -- e.g.,...
0
8269
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8203
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 synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8642
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 captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8368
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 most users, this new feature is actually very convenient. If you want to control the update process,...
0
8512
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 choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6125
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 instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4206
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2630
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
2
1515
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.