word-2007

Bug in Word 2007 ConditionalStyle

I'm using the Word 2007 object model to manipulate tables. Whenever I read the Shading or Borders properties of a ConditionalStyle object for a table's style (using VBA or C#), it resets the table's applied conditional styles to Header Row, Banded Rows, and First Column, and it clears all table-level formatting (borders and shading). ...

create agenda that automatically adjust time in word 2007

hi, how will i create a table based agenda in word 2007 that will automatically updates the time assigned to each speaker when ever i change time allocations i want to create some thing like this which is an excel sheet but want to do this in word http://office.microsoft.com/en-us/templates/TC300013331033.aspx?CategoryID=CT101172311033...

When I insert BuildingBlockEntries in Word2007 VBA, can I add other params than Where:= and Rich Text?

In example: For Each mytemplate In Templates If mytemplate.Name = "Normal.dotx" Then _ mytemplate.BuildingBlockEntries("Leeg").Insert Where:=Selection.Range, RichText:=True Next ...

Split documents in Word 2007

I have a couple of word documents and want to refer to and view specific sections of these. I thought about splitting the sections into seperate documents and then just viewing the correct files but is it possible to do it a nicer way? I thought about command-line switches for scrolling down to the correct chapter but haven't found any...

vba word 2007 - protect document but enable toolbars

I have a document with sections that are protected and unprotected. With Word 2003 the sections that were unprotected had formatting enabled - specifically the bullets and numbering. Now with Word 2007, even though the same sections are unprotected, the bulleting and numbering is disabled. Is there anyway to enable this? I tried playing...

How can I use Microsoft Word's spelling/grammar checker programmatically?

I want to process a medium to large number of text snippets using a spelling/grammar checker to get a rough approximation and ranking of their "quality." Speed is not really of concern either, so I think the easiest way is to write a script that passes off the snippets to Microsoft Word (2007) and runs its spelling and grammar checker o...

C#: Create/Insert Excel 2007 charts into Word 2007

How do you create and then insert an Excel 2007 chart in Word 2007 with office interoperability? Important: I do not want to save an Excel file to create a chart. ...

Why does MSWord2007 not accept my changes to a .dotm file?

According to the notes on office .dotm files, they are similar (or the same) in structure to the .docx files - in other words a zip archive. If I extract the contents of a .dotm file (using an archiving tool), and then recompress the resulting files back into a .dotm file, preserving the structure (file locations) exactly - MSWord2007 c...

Code for adding Content Controls Word 2007 C#

Hey all, I was wondering if anyone has any idea how I can add Content Controls to a Word Document (Office 2007) from the Document Task/Action Pane via C#. The goal is the following: I want to have categorized information in the Task/Action Pane and have the user fill out the info there. Once they have filled out that information they...

Unable to call method: GetVstoObject

All, Cannot I have created a Word2007 Document Project and I'm trying to retrieve the content controls on the page via the GetVSTOObject method but it can not find the Microsoft.Office.Tools.Word.Extensions library after I have referenced the Microsoft.Office.Tools.Word.v9.dll as suggested on the MSDN site. I would greatly appreciate ...

C#: How can I create a header in a table for each new page with Word interop?

I am trying to create a table with a header. I want this header to be repeated for each new page that the table takes. How can I do this in C# with Word 2007 Interop? ...

How do you change the content of a content control in Word 2007 with OpenXml SDK 2.0?

About to go mad with this problem. I'm sure it's so simple I'm just missing it, but I cannot for the life of me find out how to change the content of a content control in Word 2007 with the OpenXml SDK v2.0 in C#. I have created a Word document with a plain text content control. The tag for this control is "FirstName". In code, I'd like...

.NET OpenXML SDK 2 RunProperties are Null

Hello, I'm trying to read Word 2007 docx document. The document looks fine inside Word, but when i try to read id using my code, all Run objects have RunProperites set null. The property that I'm most interested in is RunProperies.FontSize, but unfortunately it is null as well, the only property I can access is InnerText. My Code l...

How do I open word in an IFrame without locking the document?

I am trying to open a docx document in an iframe dynamically using a asp.net hyperlink. The user should then be able to alter some content controls that are bound to a custom.xml in the document. Later on I want to extract this data using the open xml sdk. The document opens properly in the iframe and everything seems fine. However, wh...

Using COM to open Word

Hello! I am actually trying some codes i found from http://php.net/manual/en/class.com.php <?php // starting word $word = new COM("word.application") or die("Unable to instantiate Word"); echo "Loaded Word, version {$word->Version}\n"; //bring it to front $word->Visible = 1; //open an empty document $word...

Run word on server for COM to work??

I got this from php.net website. This is related to the problem I am having with tho code below. Can anyone explain me what the following does. I am using Vista. What does running Word on server implies? In order to get the Word example running, do the following on the server side. Worked for me... 1. Click START-->RUN and ente...

In Word, Programmatically Open New Document Dialog

I am looking for a way to programatically open the "New Document" dialog in Word 2007. It is the same one you get when you select File->New . You can also open it using the FileNew macro or the "New..." menu command. However, I have been unable to find a way to do this programmatically. I have tried: Application.Run MacroName:="Fil...

Office Word 2007 Interop - Header FieldCodes not showing up in my code, but are when viewed with Word

Hello, I'm writing an application in Delphi (have two over revisions of it written in both C# and Visual Basic, also). In my C# and Visual Basic version, I did something like the following to loop through the header/footer FieldCodes: // Supress filename, date and username field codes in headers fieldCount = WordApp.ActiveDocum...

Repurpose builtin Word commands - access original command within repurposed function

It is possible to repurpose a Word builtin command in Word 2007 using the customUI.xml file. Example: <customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui"&gt; <commands> <command idMso="Save" onAction="MySave"/> </commands> </customUI> I then have to define a callback function in VBA which is used ins...

How to Jump to a Bookmark in Word-VBA and insert text?

I am trying to create a Word document with a very simple word macro. The macro searches for a bookmark that I have placed in the text and then adds a date, 2 weeks into the future, at that location. But when I create a new document from the template I keep getting bookmark not found. I have been through it loads of times and sometimes t...