Office Integration Pack


A LightSwitch Extension that provides integration capabilities with Microsoft Office 2010.

(9) Review
Visual Studio
2012, 2010
Download (25,314)
E-mail Twitter Digg Facebook
Add to favorites
Reviews (9)
Q and A (20)
Sign in to write a review
Sort by:

by Exp3rt | December 28 2015

It's not support with VS 2013

by Xpert360 | October 11 2012

Really good start. We are offering some time and resource to help with enhancements over on codeplex. We have enhanced the area of Excel export significantly.

by Bart Doise | July 22 2012

by Kostas Kolotouros | February 15 2012

What I'm missing is an Excel.Export(string fields) overload that creates a new workbook and exports only the selected fields. With the existing overloads an Excel workbook must pre-exist in order to extract some of the fields.

by Eng. 3oon | January 13 2012

is there any way to map multiple Entities into one word document ??

how can i do that ??

by KeithSware | November 20 2011

I have vs2010 ultimate SP1rel on an windows 7 SP1 box, the install error was "This extension is not installable on any currently installed products". The supports section in the web description page said 2010 was supported but this was not true in my case for my varient of visual studio. Suggest you download and test a trial version of VS2010 ultimate. I dont have any varient of VS11 preview installed. I also have a varianet of VS2008 installed called 'SQL Server Business Intel DevStudio'. I have office 2007 and also office 2010 that were installed onto the box in that order. All office products are fully patched and service packed.

Steve Hansen November 29 2011
| Edit |

Hi Keith - sorry this didn't work for you. Did you install Visual Studio LightSwitch? It isn't included by default on versions of Visual Studio.

by Jamil MilheM | October 10 2011


by Jan Van der Haegen | September 16 2011

My Vote of 5, only just had the time to check it out and already using it in a presentation in two hours! Thank you!

by PowerBala | September 13 2011

Sign in to start a discussion

  • Visual Studio 2013
    2 Posts | Last post December 09, 2013
    • Great extension. Is there going to be a version that supports Visual Studio 2013?
    • I agree, I hope you guys continue to maintain this product for VS 2013 users.
  • Office 2013
    1 Posts | Last post October 18, 2013
    • Hi, are there any plans to support Office 2013 in the near future or any upcoming vesion?
  • Exception when running sample code
    3 Posts | Last post October 03, 2013
    • Hello,
      I tried running the sample solution, but when I opened the Books screen and clicked the Export To Word button, I got the following exception...
      System.ArgumentException was unhandled by user code
        Message='Document' is not the expected type of object. Expected object should be a Word.Document object.
      Parameter name: Document
             at OfficeIntegration.Word.Export(Object Document, String BookmarkName, Int32 StartRow, Boolean BuildColumnHeadings, IVisualCollection Collection, List`1 ColumnNames)
             at OfficeIntegration.Word.Export(String DocumentPath, String BookmarkName, Int32 StartRow, Boolean BuildColumnHeadings, IVisualCollection Collection, List`1 ColumnNames)
             at LightSwitchApplication.EditableBooksGrid.ExportToWord_Execute()
             at LightSwitchApplication.EditableBooksGrid.DetailsClass.MethodSetProperties._ExportToWord_InvokeMethod(DetailsClass d, ReadOnlyCollection`1 args)
             at Microsoft.LightSwitch.Details.Framework.Internal.BusinessMethodImplementation`2.<TryInvokeMethod>b__5()
             at Microsoft.LightSwitch.Utilities.Internal.UserCodeHelper.CallUserCode(Type sourceType, String methodName, String instance, String operation, ILoggingContext context, Action action, String additionalText, Func`1 getCompletedMessage, Boolean tryHandleException, Boolean swallowException, Exception& exception)
      This happened on the following line in the ExportToWord_Execute() method...
        OfficeIntegration.Word.Export(WordFile, "PlainTable", 1, true, this.Books);
      Any idea what's going wrong? This looks like a great extension, but I haven't been able to run it at all.
    • Hi Youssu,
      Even I am getting the same exception, did u get the solution for this? Can you please give me the source code to export to word, I even tried the sample given in:
      even this is failing at line: Dim doc As Object = OfficeIntegration.Word.GenerateDocument(WordFile, 
                                                                          Me.Customer, custFields)
      as conversion failed to IEntityObject.
      Any help to run this will be helpful to me.
    • I am having similar issues as earlier posts with error message 'Document' is not the expected type of object. Expected object should be a Word.Document object.
      This started to happen when I installed VS2013 preview alongside VS2012 which I am using with Officeintegration. Anyone who has found a solution in the meantime?
  • Export into pdf without opening Word
    1 Posts | Last post April 23, 2013
    • Hi,
      how do you export files created with Office Integration pack without it opens Word
    1 Posts | Last post August 02, 2012
    • This Q&A section is not monitored. Please post any questions about the Office Integration Pack to it's CodePlex site at:
  • Is there a way to export data with in empty doc file same like excel?
    1 Posts | Last post May 17, 2012
    • I dont have Office 2010, so I could not create a template, I am trying to work with the empty document file, why doesn't it work the same way like excel export? 
  • Multiple Entities in one Word document?
    1 Posts | Last post April 09, 2012
    • is there any way to map multiple Entities into one word document ?? 
      how can i do that ?
  • PDF Output
    1 Posts | Last post March 21, 2012
    • I've been working with the word generatedocument feature and passing data from my LS application to it.  That seems to be working well.  I'm also able to save the output as pdf.  My question is this:  is there a way to suppress the word application from becoming visible when generatedocument is called?  I want to use the  content control aspects of Word but only output to PDF.  I don't see any calling parameters that would accomplish that.
  • Output Formats messed up??
    1 Posts | Last post March 21, 2012
    • Hi,
      Having trouble with 2 datatypes. DATE and MONEY.
      Outputting a SHORT DATE (dd/mm/yy) (That's how it appears everywhere in my app), but when output to WORD Doc, it appears as a Full Date/Time stamp.  (ColumnMapping technique used for this field)
      When outputing data defined a MONEY, values appear in app as $9999.99. When output to word getting 9999.9999  (4 decimal places and no $ sign)  (Bookmark, ExportEntityCollection used for these money fields).
      Any ideas on how to correct?
  • How!?
    2 Posts | Last post February 04, 2012
    • I am so lost on how to use this extention.
      The instructions included with the download are not helping much.  And if I try to move the code over to a different project much of the code doesn't seem to be declared properly.  I thought knowing a bit of VBA would have given me enough knowledge to use lightswitch.  With enough time I might be able to figure this out but I'm not so sure.
      Do we have to use the project sample or how do I use this extention for my own program?
      The function I am interested in is the import function.  The rest of it while useful for other isn't of interest to me at this time.
      How is lightswitch different than VBA?  I declared a varible dim USERNAME as string and then the next line Username = Environ("USERNAME") but lightswitch is telling me that username isn't declared.  I was trying to write this code on button attached to a screen name Toner Screen
    • Obviously I am very new to VB. I have learned everything I do know through crash coarse google searches...
1 - 10 of 20 Items