mercredi 12 août 2020

C++ : Linker Error whilst Importing Excel

I am attempting to import Excel into Visual Studio. Here is my ExcelImports.cpp


#ifndef ExcelImports_CPP
#define ExcelImports_CPP

#import "C:\Program Files (x86)\Common Files\microsoft shared\OFFICE12\MSO.dll" rename("DocumentProperties", "DocumentPropertiesXL") rename("RGB", "RGBXL")
#import "C:\Program Files (x86)\Common Files\microsoft shared\VBA\VBA6\VBE6EXT.olb"
#import "C:\Program Files (x86)\Microsoft Office\Office12\EXCEL.EXE" rename("DialogBox", "DialogBoxXL") rename("RGB", "RGBXL") rename("DocumentProperties", "DocumentPropertiesXL") rename("ReplaceText", "ReplaceTextXL") rename("CopyFile", "CopyFileXL") no_dual_interfaces


#endif

I am getting the error that these source files cannot be opened. How do i resolve these an why is this error occurring even though these files paths are correct?

enter image description here

Aucun commentaire:

Enregistrer un commentaire