Solved

Opening Office files in different modes from ASP.NET

Posted on 2004-09-09
4
330 Views
Last Modified: 2010-04-06
Hello, all!

I have a web application developed with asp.net, vb.net.

My client wants to have this kind of feature:

When the user clicks on the links to Office files (Excel, Word, Visio), the files are opened based on the user profile, in other words, the files are either open in read-only or in full-mode.

I tried several different solutions which I found on the internet but none of them worked properly or required a lot of configuration.

1) I found a client-side vbscript which allows opening office files. It works ok for for simple html pages but in my application it doesn't work giving me Activex component error. http://support.microsoft.com/support/kb/articles/Q178/2/22.ASP

2) Also, I tried using Microsoft.Office.Core library (for example,  
Dim objExcel as New Excel.Application
objExcel.Visible = true
objExcel.Workbooks.Open (location))

to do the same thing but unfortunately as I discovered, it doesn't allow opening the files on the fly. However, it opens the files for Windows-form application.

3) I installed Office Web component 11 and I tried using it to achieve the same goal but I was unlucky again.

So, is there a way to open Office files in different modes from the web application?

I need clear explanation with some code snippet in vb.net or c# or some scripting language.
May be, someone had the same kind of problem.
0
Comment
Question by:EugeneTrukhin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
webwoman earned 500 total points
ID: 12017749
ANY internet based use of Office programs will be accessed through the IUSR_machine account ON THE WEB SERVER. Unless you set up accounts for all your users AND turn off anonymous access, reguiring them to login, they will ALL be the anonymous user, with NO write access to ANYTHING.

They are NOT using the files on THEIR systems -- they're using them on the WEB SERVER. Huge difference.
0
 
LVL 1

Author Comment

by:EugeneTrukhin
ID: 12018461
Clarification:

well,  the users need to login, so there are no anonymous users, right now users can click on the links which open the office files in a new window, and they are able to change the content and store it on the web server. Yes, the links are to the files on the web server.

is it clear?
0
 
LVL 19

Expert Comment

by:webwoman
ID: 12022871
Then you need to set the permissions on the web server, on the file directly. It still might not work, but it's the only thing that's even got a chance.
0

Featured Post

Enroll in June's Course of the Month

June’s Course of the Month is now available! Experts Exchange’s Premium Members, Team Accounts, and Qualified Experts have access to a complimentary course each month as part of their membership—an extra way to sharpen your skills and increase training.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preface This is the third article about the EE Collaborative Login Project. A Better Website Login System (http://www.experts-exchange.com/A_2902.html) introduces the Login System and shows how to implement a login page. The EE Collaborative Logi…
There are two main kinds of selectors in CSS: One is base selector like h1, h2, body, table or any existing HTML tags.  For instance, the following rule sets all paragraphs (<p> elements) to red: (CODE) CSS also allows us to define our own custom …
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question