ms-office

VSTO 2003-2010 add-in compatibility

流过昼夜 提交于 2019-12-03 20:24:38
问题 I want to create an Office add-in compatible with Office 2003, 2007 and 2010. VS2008 allows for add-in 2003/2007 creation while VS2010 allows 2007/2010. I have both installed. I have developed 2007/2010 add-ins before as a 2007 add-in that worked automatically with Office 2010. The problem I am facing now is the lack of ribbon interface in Office 2003 and how to structure the project so that a single add-in is compatible with Office 2003-2010. Considering differences between various Office

Create Excel workbook in asp.net

心已入冬 提交于 2019-12-03 20:12:19
I need to generate an excel file for a user on the fl upon button click. I was using Netoffice before which worked fine for desktop applications. But now I want to do the same thing with an asp.net app. This way my server code doesn't have an access to the client's copy of excel. What approach should I take? Use EPPlus . It allows you to create Excel spreadsheets on the server. I've used it and it worked great. It supports advanced functions. using (ExcelPackage pck = new ExcelPackage()) { //Create the worksheet ExcelWorksheet ws = pck.Workbook.Worksheets.Add("Demo"); //Load the datatable into

how to check MS office version installed on the machines

梦想的初衷 提交于 2019-12-03 17:23:27
I am working on a console app which perform some operation on registry. I am not using any interop assembly for office but i need to to know office version. How to determine which version of MS office is installed on the machine using C#. Johnno Nolan Search in (using the Registry class) HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\App Paths or HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\App Paths Version numbers are 7.0 -97 8.0 - 98 9.0 -2000 10.0 -2002 11.0 -2003 12.0 -2007 14.0 -2010 Here is a c# implementation I had the same requirement, but I also have to

Is it possible to create an Office 2003 VSTO add-in from Visual Studio 2010?

烈酒焚心 提交于 2019-12-03 17:19:55
问题 We have existing VS 2008 VSTO add-ins for Word 2003 and Excel 2003. We are unable to upgrade the Office version at this time. We have just tried to upgrade our solution to VS 2010 and it converts and compiles fine, but when building and running the add-in we receive a message saying that the required version of Office is not installed. Is there any way of getting around this issue (without upgrading to Office 2007 or 2010) so that we can use VS 2010 to build this add-in? 回答1: No,

How to convert Word and Excel documents to PDF programmatically?

為{幸葍}努か 提交于 2019-12-03 16:01:39
We are developing a little application that given a directory with PDF files creates a unique PDF file containing all the PDF files in the directory. This is a simple task using iTextSharp. The problem appears if in the directory exist some files like Word documents, or Excel documents. My question is, is there a way to convert word, excel documents into PDF programmatically? And even better, is this possible without having the office suite installed on the computer running the application? Office 2007 allows for this. I have found PDFCreator to be good, the VBA is included in sample files,

Access 2007 triggers and procedures equivalents?

做~自己de王妃 提交于 2019-12-03 15:28:43
Ok, does anyone have some good resources for Access 2007 features regarding triggers or stored procedures? Can it even do them or something similar to them? Every resource I have found on Microsoft’s help is referencing back to Access 2003, as well as many of the help manuals online. Everything is moved around in 2007, so it is a little tough to translate older help manuals. I really wanted to use ms sql, but got forced to do this small project in access, so any resources would be helpful. Cool, all of the answers so far have been helpful. Just wanted to confirm a lot of the scattered

Saving multiple Word documents as HTML through Office API

陌路散爱 提交于 2019-12-03 14:43:08
问题 I have a large amount of Word documents that I need to parse. As they all were created from the same template, I think that the best approach would be to save them as HTML files and parse the HTML itself. While it's quite easy to save a single Word document as HTML, I haven't found a way to do a bulk procedure from inside Word. Thus, I'm trying to find a way to leverage the Microsoft Office/Word API to accomplish this. How can I use the Word API to save many Word documents as HTML? Thanks in

Outlook VSTO ribbon to home tabControlId

寵の児 提交于 2019-12-03 13:46:51
I'm writing a VSTO Microsoft Outlook plug-in. The version destination of that plugin is Outlook 2007 and 2010, so I use the Outlook 2007 add-in (in Visual Studio). I have some (visual) problem with ActiveMenuBar. In Outlook 2007 it works fine, but in 2010 the ActiveMenuBar doesn't exist; it is replaced with tabControl and ribbons. I would like to check the version ( Application.Version ) and if the version is 14 (Outlook 2010) then don't add an item into ActiveMenuBar, but add a ribbon to the Home tabPage. How do I add the Ribbon into the Home tab page? For example, if I add a ribbon to the

Check for active internet connection

╄→尐↘猪︶ㄣ 提交于 2019-12-03 13:38:27
Wrote a small app that accesses a bunch of search websites and puts the results in a word document, which gets run a few hundred times a day. It saves individual search results in a number of local folders so the next time those words are searched, it grabs them locally instead of loading the website again. This works fine - even though it's not quick. People are impressed because until a few weeks ago they did this manually by literally loading up six different search websites, searching, and then copying and pasting the results in a word document. However, our Office's internet is unreliable

Automating MS Word in Server 2012 R2

邮差的信 提交于 2019-12-03 13:16:09
Firstly, please don't reply with the generic advice not to automate Word on a server or a link to the MS web page on "how to automate word on a server if you really must". I am aware of this. I have a process which runs as a Windows service and uses .Net OLE interop to automate Office (mostly just Open and SaveAs). This code has worked reliably for 8 years on literally hundreds of servers using many combinations of Windows and Office versions, both 32 and 64 bit, so I am happy that the mechanism is reliable. So far... With Server 2012 R2, it works with PowerPoint and Excel but fails trying to