RE: webbrowser in vb.net



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.


.



Relevant Pages

  • Re: Want to enable fields after combox selection
    ... and it opens up teh code and highlights HideFormText ... Dim ctl As Control 'Each control on the form ... Dim bSkip As Boolean ...
    (microsoft.public.access.forms)
  • Re: Command Button Enabled/Disabled Based on Text in Text Box
    ... See if you have Microsoft ADO XXX checked. ... References dialog. ... Class1 is the name of a control on your form and should be enclosed ... form opens. ...
    (microsoft.public.access.queries)
  • RE: webbrowser in vb.net
    ... The development team confirmed that the control WebBrowser is not able to ... 82AF-770AA9B60D77&displaylang=en (Microsoft Developer Support Office Framer ... interfaces for Open/Save/Create Office documents. ... The control opens file with Modify by default. ...
    (microsoft.public.vsnet.general)
  • Can Forms / Controls be controlled remotely?
    ... Dim rst As Recordset ... When the code runs it opens the database and recordset just fine. ... somehow that this might have allowed me to get into the Forms ... while using VB to control the Access application. ...
    (microsoft.public.vb.database.dao)