Is it possible to embed google excel in my website to edit document stored locally?
My manager asked me if it is possible to integrate the Microsoft office webapp in my own website.
Clients have excel files stored on our website, we want to know if it is possible for them to open the file with a web excel page, edit the file and save the modifications. For now, they use SharePoint so it is easy for them but we intend to use an other platform.
Our client can have all the license we need.
I searched but I didn't find any solution.
I know you should be able to do this with ASP and the .Net Framework. SharePoint uses ASP pages, so you may try to do something simpler.
If you go over the Internet you'll see several solutions because people do this too.
e.g. a thing you can do is to use Open XML API to do this, and it is like reading / modifying a flat file on the server. A restriction is it has to be .xlsx / 2007 format onward.
Related
My first question on stackoverflow, I hope I am following the rules.
Anyhow, as the title suggests, I need to figure out how to programmatically add pages to a wiki library. I set up upwards of 30,000 rows in Excel, VBA'd them into txt files containing html that portray articles, and now they are sitting in a folder with nowhere to go. They need to go into a wiki library on SharePoint, where they will be referenced by users in their articles. Two parts:
On single-file upload, cannot upload aspx files. I upload as txt or html and it goes fine. Then I try to change them to aspx. Illegal.
Cannot upload more than one file at a time. Once I figure out #1, this will be an issue.
I assumed there must be a way to mimic whatever the "wikification" process is for files programmatically. Microsoft's how-to on file uploading requires a Sharepoint Project, which requires VS Professional and running SharePoint locally. Neither of these is practical.
Thank you and godspeed.
You could write a small Powershell Script or Commandline application for example in C# or VB. Copy your files to the server and execute your script/app on the SharePoint server. Connect to your SharePoint like the following:
using Microsoft.SharePoint;
...
SPSite site = new SPSite("mysiteurl");
SPWeb web = site.OpenWeb();
// your code goes here
web.dispose();
site.dispose();
...
Then get the directory programmatically where your files reside.
If this was successful, loop through all files in your folder and upload them programmatically to the WIKI Library.
Sound complex, but if you search for the single topics, you will find a lot of solutions/code out there.
You could also write a Console Application which can connect remotely to the SharePoint Server without the need to be executed on the SharePoint itself. In this case you would need to use the Client Object Model (CSOM).
The Office 365 Patterns and Practices site is a great reference. It has a comprehensive sample for creating wiki pages using CSOM here
can any one help me to find out the solution to show/Read the word
documents in asp.net mvc any example or any suitable links. searched a lot on internet for suitable
article but did not find any thing helpful. i have implemented the
download functionality of the document. but can not able to read or
preview the documents.
You could use the Office Web Viewer provided as a service from Microsoft .
What is the Office Web Viewer?
It’s a service that creates Office Web Viewer links. Office Web Viewer links open Word, PowerPoint or Excel files in the browser that would otherwise be downloaded. You can easily turn a download link into an Office Web Viewer link to use in your website or blog (e.g., recipes, photo slide show, a menu, or a budget template).
Office Web Viewer: View Office documents in a browser
Some benefits of the Office Web Viewer include:
You don’t need to convert Office files for the web (e.g., PDF, HTML).
Anyone can view Office files from your website or blog, even if they
don’t have Office.
It keeps eyes on your website or blog, because readers don’t need to
download the file and they stay in the browser.
One link will work for computers, tablets, and mobile phones.
To manipulate .docx files (as well as .xlsx, .pptx, etc.) you would use Open XML SDK (also available as installer from Microsoft download centre).
The PowerTools for Open XML, which greatly simplifies working with Open XML SDK, contains functionality for
High-fidelity conversion of DOCX to HTML/CSS using HtmlConverter.cs
I've only used this SDK and Powertools to manipulate Word documents, so could not say much about conversion to HTML/CSS. But this could be one of your options for previewing Word documents, although it is a complicated way of solving your problem.
Try the MVC viewer in Gnostice XtremeDocumentStudio .NET.
ASP.NET MVC document viewer using ASPX and Razor engines.
DISCLAIMER: I work for this company.
I can export to page as excel file via this code below:
response.contenttype = "application/vnd.ms-Excel"
response.Addheader "content-disposition", "attachment; filename=test.xls"
But I want to create multiple tabs on the same excel file, how I can do it?
Thanks for helps.
You cannot do that using the response.contenttype directive. that command only transforms a page into excel so you do not have the ability to create a new page as all of your html will be read as one page.
The solution depends on what your requirements are.
Free
The only free solution I know is building a page and pushing it to the browser as an XML file. If you create the file you want in excel and then save it in an XML format, you can open that file and see how the page should be build in asp.
Pros Its free. you do not need permission to install anything to the server. You will just be passing an xml file to the client.
Cons Excel is not the default viewer for xml files, notepad usually is. Most people will not understand how to open your file in excel. This means that this method is really only good for internal applications where you can change everyone's computer to open XML files in Excel by default.
3rd Party Program
When I needed to accomplish this same task I had entertained using 3rd party programs in classic asp. I wish I could remember the program but it would have cost around ~$1,000 to use.
Pros These programs are feature rich and will allow you to do anything you could want in exporting to excel. They are also cleaner and a bit simpler to use over writing your own XML file to open in excel.
Cons Costs money. may require server permissions you do not have. Most programs require you to save the file to the server before serving it to the client
ASP.NET
You can choose to instead create a new page in asp.net and use its excel features to create the file you need.
Pros Also free. Same extensive feature set available in most 3rd programs for classic asp are available with this method.
Cons classic asp and .net are not able to communicate directly so things like password protection on the page will become an issue if that is needed. You obviously need to know or learn the .net framework. Files are saved to the server before being sent to the client.
I have multiple Excel Web Parts in my SharePoint 2010 site. Each web part is connected to an Excel work book which is generated automatically by a scheduled task on a separate server. Given this, is there a way to automatically map a newly generated excel file to an existing excel web part instead of manually updating them?
I saw a tutorial but it uses the SharePoint dll and other dlls which are found from the SharePoint server itself and as far as I know, I can only execute these items if I have SharePoint installed locally. Is there any way to make it work without having to install SharePoint locally? By the way I was referring to this tutorial from MSDN.
Edit
I was able to create web parts programmatically using SharePoint.Client.WebParts but I'm having problems creating Excel Web Access Web Parts.
I was able to make it work by using the same concept found in this page.
All that I needed to do was properly escape quotation marks from the exported web part file in order to map the correct file.
I am running Sharepoint 2010 with Office Web Apps. By default, any document of type .doc, .ppt, etc... will open within the browser from the document library. This is fine, however I am using a web part that is pulling in an XML feed that displays a search engine result list that contains URL links to Word and PPT documents.
I would like to have these links behave the same way as they do in the document library (open in browser), however the user is prompted to download these files instead. Is it possible to dictate this behavior in Sharepoint?
Unfortunately I don't think this is possible unless the documents are hosted in SharePoint and the Office Web Applications feature is activated. The in-browser behaviour is made possible by this server-side feature. I assume that the search-engine derived links you are getting will not, in general, be SharePoint hosted documents.
It is possible to open documents in the browser, but this is a client setting and will depend on the client operating system. You say you want to control this from SharePoint, and I can't think of any way you can do this.