473,399 Members | 3,832 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

System.Windows.Forms.WebBrowser and AxSHDocVw Differences

Joe
HI

Trying to figure out the difference between these 2 browser

I am embedding a MS office Document (Word/Excel) in a WebBrowser on a Form

With AxSHDocVw I can do the following to save the current document
object o = new object();
axWebBrowser1.ExecWB(SHDocVw.OLECMDID.OLECMDID_SAV E,SHDocVw.OLECMDEXECOPT.OLECMDEXECOPT_DONTPROMPTUS ER,
ref o, ref o);

oDocument = null;

But Windows.Forms.WebBrowser has no ExecWB method - I assume the Forms
webBrowser will be with DotNet v2.0 so I am assured it will

be on the pc - so I'd rather just it. How do I get a handle of the Document
within Windows.Forms.WebBrowser to save the file???

Thanks
Dec 18 '06 #1
1 5131
Joe,

On a side note, you should pass Type.Missing.Value for the last two
arguments.

What you could do is call the ActiveXInstance property of the WebBrowser
control to get the ActiveX control.

You should also define the IWebBrowser2 interface somewhere in your code
(or, if you want, set a reference to the ocx which has the web browser
control).

Case the object returned by the ActiveXInstance property to the
IWebBrowser2.ExecWB method, and it will do what you want.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Joe" <hc******@yahoo.comwrote in message
news:%2******************@TK2MSFTNGP02.phx.gbl...
HI

Trying to figure out the difference between these 2 browser

I am embedding a MS office Document (Word/Excel) in a WebBrowser on a Form

With AxSHDocVw I can do the following to save the current document
object o = new object();
axWebBrowser1.ExecWB(SHDocVw.OLECMDID.OLECMDID_SAV E,SHDocVw.OLECMDEXECOPT.OLECMDEXECOPT_DONTPROMPTUS ER,
ref o, ref o);

oDocument = null;

But Windows.Forms.WebBrowser has no ExecWB method - I assume the Forms
webBrowser will be with DotNet v2.0 so I am assured it will

be on the pc - so I'd rather just it. How do I get a handle of the
Document within Windows.Forms.WebBrowser to save the file???

Thanks


Dec 18 '06 #2

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

Similar topics

3
by: Jay | last post by:
Hi all, May i know if there is any way by which we can render a given HTML inside .NET Windows Forms? We had the Web Browser controls in Visual Studio 6. Is there a follow-up of that in...
7
by: David Elliott | last post by:
I have created an application that will dynamically load other DLLs (plugins). The new plugin is a winform with an embedded IE Browser. I am wanting to have the form to run in its own thread....
0
by: Matthias Kwiedor | last post by:
Hi! I want to create a WebBrowser Control at runtime. So i ported the "at start creation" of the Control to a new routine. Everything works fine, but i implement the BeforeNavigateFix and a...
4
by: Supra | last post by:
I have a tab control in a which a few of the tabs include an AxWebBrowser browser control. Let say i have currently tabpage2 and i typed url in combobox when i pressed enter it doesn't display...
4
by: Toma Marinov | last post by:
Hello ! I made some test with webbrowser control in VS.2005. When I load a word document in webbrowser through .Navigate method (from my hdd), I want to get the stream of the loaded doc file with...
5
by: Boki | last post by:
Hi All, I am using webbrowser control, it is very often to happen: A first chance exception of type 'System.IO.FileNotFoundException' occurred in System.Windows.Forms.dll but sometimes...
2
by: Qiang | last post by:
Hi, Anybody knows how to convert an instance of SHDocVw.WebBrowser to System.Windows.Forms.WebBrowser? Or is it possible? thanks, Qiang
3
by: David | last post by:
I would like to use a AxSHDocVw.WebBroswer control in a Windows service- is this possible without creating a form? I added the reference I usually use to add this object in a Windows Application...
0
by: =?Utf-8?B?Q29kZVJhem9y?= | last post by:
I am converting a windows application which contains a web browser control into an ASP.net application. The Windows project references all manner of html controls in the WebBrowser control and...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...
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
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...

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.