Posts Tagged ‘Word’

Inner details of DPI scaling in Office COM add-ins

Today, I’m following Microsoft recommendations and using code fragments they provide to investigate the behavior of a System.Windows.Forms.Form (simply a form)... Read the rest of this entry →

Office COM add-ins and DPI awareness: research and analysis

In the first blog of this series, I showed issues related to using several monitors with different DPIs. To get an explanation of those pretty confusing results, let’s check resources available on the web.... Read the rest of this entry →

Issues with Windows mutli-DPI scaling and Office COM add-in panes and forms

Quite often these days you see this configuration: a notebook and an external display or two connected to the notebook. All these displays may have different DPIs. This is a typical environment where DPI-related issues reveal themselves. ... Read the rest of this entry →

Releasing COM objects: Garbage Collector vs. Marshal.RelseaseComObject

Just recently we've got a comment declaring one of our blogs on releasing COM objects "wrong and misleading": the author says Marshal.ReleasingComObject() and related things made him spend "lots of time on writing code that is totally unnecessary" and provides many links supporting the idea that you can use GC.Collect() to get rid of non-released COM objects.... Read the rest of this entry →

New version of Add-in Express sample COM add-in projects

Quick news: we've developed a new version of sample COM add-in projects that we provide in the downloadable archive on the Add-in Express .NET Downloads page... Read the rest of this entry →

Add-in Express for Office issues on multiple monitors with different DPI settings

Microsoft has published Office 2016 build 8828.2010 through its Office Insider update channel. That build supports multiple monitors with different DPI settings; the support relies on the API changes provided by Windows 10 Creators Update.... Read the rest of this entry →

Localization of Office add-ins using forms-based resources

The article describes how to create a localized version of an Office add-in by using regular forms-based resources without having to apply them manually to each component, form or control... Read the rest of this entry →

Office context menu add-in for Excel, Outlook, Word, PowerPoint

The blog is about an add-in (with the source code) that adds a button to all context menus of Excel, Outlook, PowerPoint, Project, Publisher, Visio and Word in Office 2010-2013. The button shows the name of the context menu.... Read the rest of this entry →

How to create Word Apps for Office 365

We thought that after we investigated how to create customization for Google Docs and Google Sheets, it is about time we tackle the Napa Office 365 development tools again. We'll create a Task Pane app for Microsoft Word, similar to the one we created for Google Docs that will allow the user to shuffle either the selected words, sentences or paragraphs in a Microsoft Word document... Read the rest of this entry →

Working with Microsoft Word templates: C# sample

This is a continuation of the work we did in my previous article. The difference is, we will use a pre-built template for inserting data. Instead of inserting data "willy-nilly", we need to find where to insert it within the document's pre-defined structure... Read the rest of this entry →

Populating Word documents with data from external sources (database, SharePoint, Outlook, etc.)

Today, I have three main C# code samples that insert data into Word. Each sample method creates and then goes to town inserting data. It is a simple strategy and works very well to get you started integrating data into Word... Read the rest of this entry →

Working with Word document properties, bookmarks, content controls and quick parts

Even though the object model can be somewhat daunting it gives you amazing flexibility and power over programmatically bending MS Word to your will. In today's article we'll have a look at the Microsoft Word document properties, content controls, quick parts and bookmarks, and how you can access and use these objects in your own add-ins... Read the rest of this entry →

Using custom XML parts in Word add-ins

Custom XML parts are chunks of XML that reside within a Word document. They are not part of the document, per se, because they are not visible to the user. Starting with Office 2007, the Office file formats are XML-based and are comprised of XML parts... Read the rest of this entry →

Working with multiple Microsoft Word documents: C# add-in example

In today's article we'll take a look at how you can combine information and text from various existing Microsoft Word documents into a single document. We'll create a Word add-in that will allow the user to select and insert different paragraphs from one or more existing Word documents, into another document... Read the rest of this entry →

Working with Word document designs, styles and printing

Designing Microsoft Word documents is not all that different from designing a web page; you want to keep the content and the design separate. In Word, you keep them separate by utilizing styles. Styles include a plethora of design elements (e.g. font, borders, paragraph format, etc). Let's have some fun with them via code... Read the rest of this entry →

Working with Word document content objects

Microsoft Word is about the authoring of documents. Documents contain pages, paragraphs, sentences and more. Today, I want to wade into the waters of manipulating Word document content. The plan is to get your feet wet by providing an overview of the key objects along with code samples... Read the rest of this entry →

Have any questions? Ask us right now!