0

I'm building a program that makes excel based reports using xlsx files using the Microsoft.Office.Interop.Excel library and Visual Studio 2010.

I have a xlsx file with 2 charts, and some styles. Using...

Dim LibroExcel As Excel.Workbook
Dim HojaExcel() As Excel.Worksheet

LibroExcel.Worksheets(1).copy(After:=LibroExcel.Worksheets(i))

HojaExcel(i) = LibroExcel.Worksheets.Item(i + 1)

... I copy that sheet to another sheet until the for instruction I use ends.

The problem: In a system with Windows8 when I use this function, the charts are not copied from one sheet to the next one. But if I do the same on a Windows 7 system, it works. Both systems are using the same version of Excel.

Aiken
  • 2,628
  • 2
  • 18
  • 25
enekofer
  • 11
  • 1
  • 6

1 Answers1

0

I have been searching on the internet, and following the steps on the next post i have resolved my problem:

https://stackoverflow.com/a/13174856/4587472

Also i applied the next steps because the first time i didn't found Microsoft Excel Application: On 64 bit system with 32 bit Office try this:

  1. Start
  2. Run
  3. mmc -32
  4. File
  5. Add Remove Snap-in
  6. Component Services
  7. Add
  8. OK
  9. Console Root
  10. Component Services
  11. Computers
  12. My Computer
  13. DCOM Config
  14. Microsoft Excel Application

Anyway, can someone explain what this steps really do? (This steps and the post steps)

Community
  • 1
  • 1
enekofer
  • 11
  • 1
  • 6