RE: webbrowser in vb.net
- From: Komandur Kannan <Kannan@xxxxxxxxxxxxxxx>
- Date: Tue, 18 Sep 2007 06:00:04 -0700
Hi,
thanks for support and suggestion,
well, as you said,...
When a word document is opened, even with ReadOnly, a edit lock will be
added to the file. If the document is not closed, the next open of the file
will pop out a dialog that says the file is edit locked by another user.
Therefore, if multiple users want to open the file, we could copy the doc
from server to user's clients first, so as to avoid such dialogs.
--- this is very difficult, since the data entry operator may fill this doc
file by often to give some information for the operations team working
around, only one data entry operator will do update this file and the number
of users may required to use this file as the INFORMATIVE for their daily job
routine, so 24/7 operations team is working with the application background
of this doc file and whenever required the data entry operator may required
to update the file, so only one place for modifications and n number of users
for the readonly mode,
here the quite complication why i feel is, the operations team is working
in different places to access the file, so its difficult for me to give
updations for all the client machine manually whenever the changes happend,
is it any workaround for this.. and the doc file is with security and with
pictures and well formatted text for data ( its basically a information),
plz advice
thanks in advance for understanding the request
Anis
"Jialiang Ge [MSFT]" wrote:
Hello,.
The development team confirmed that the control WebBrowser is not able to
directly open a document with ReadOnly. But Microsoft provide another
control to host Office documents: dsoFramer
http://support.microsoft.com/?id=311765
The control (source and sample) can be downloaded at
http://www.microsoft.com/downloads/details.aspx?familyid=CE2CA4FD-2169-4FAC-
82AF-770AA9B60D77&displaylang=en (Microsoft Developer Support Office Framer
Control 1.3 Sample (KB 311765))
Please NOTE: there are some known issues of dsoFramer when it is used to
open Excel workbooks. For instance, it might throw an exception: The
document is not associated with an ActiveX Document server.
The control itself is developed in Visual C++ and it exposes its own
interfaces for Open/Save/Create Office documents. The samples are written
in VB and VB.NET. They show how to use the control to open doc/xls/ppt in
Windows form or web form.
Take the project Vb7TestApp as an example here:
In the sub btnOpenFile_Click of Form1.vb, it creates an object of dsoFramer
(AxFramerControl)
Dim ctl As AxDSOFramer.AxFramerControl
ctl = GetFramerCtlFromIdx(idx)
Then use the control to open a document:
ctl.Open(OFileDialog.FileName)
The control opens file with Modify by default. To make it open with
ReadOnly, we could specify the parameter 'ReadOnly' in the Open method:
ctl.Open(OFileDialog.FileName, True, Type.Missing, Type.Missing,
Type.Missing)
In this way, the doc files with Modify password will be opened without the
password dialog popped out.
In order to hide all the menus, command bars, etc in the control, please
add the following codes after the creation of ctl
ctl.Menubar = False
ctl.Titlebar = False
ctl.Toolbars = False
In order to set the default view of doc as Web View, please add the code
below after the ctl.Open
ctl.ActiveDocument.ActiveWindow.View.Type = 6
When a word document is opened, even with ReadOnly, a edit lock will be
added to the file. If the document is not closed, the next open of the file
will pop out a dialog that says the file is edit locked by another user.
Therefore, if multiple users want to open the file, we could copy the doc
from server to user's clients first, so as to avoid such dialogs.
For more information about dsoFramer, please refer to the KB article
http://support.microsoft.com/?id=311765
If you have any other concern or need anything else, please feel free to
let me know.
Sincerely,
Jialiang Ge (jialge@xxxxxxxxxxxxxxxxxxxx, remove 'online.')
Microsoft Online Community Support
=================================================
When responding to posts, please "Reply to Group" via your newsreader
so that others may learn and benefit from your issue.
=================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
- Follow-Ups:
- RE: webbrowser in vb.net
- From: Jialiang Ge [MSFT]
- RE: webbrowser in vb.net
- References:
- RE: webbrowser in vb.net
- From: Jialiang Ge [MSFT]
- RE: webbrowser in vb.net
- From: Komandur Kannan
- RE: webbrowser in vb.net
- From: Jialiang Ge [MSFT]
- RE: webbrowser in vb.net
- Prev by Date: RE: webbrowser in vb.net
- Next by Date: VS 2005 App.Config Mystery Settings
- Previous by thread: RE: webbrowser in vb.net
- Next by thread: RE: webbrowser in vb.net
- Index(es):
Relevant Pages
|