Hello all,

I am working on a project and want to load excel libraries into C++ so that I can read/write data into cells.
#include <iostream>
#include <cmath>

// Office XP Objects (2003)
#import "C:\Program Files\Common Files\Microsoft Shared\OFFICE12\mso.dll"\
	rename("DocumentProperties", "DocumentPropertiesXL")\
	rename("RGB", "RBGXL")

//Microsoft VBA objects
#import "C:\Program Files\Common Files\Microsoft Shared\VBA\VBA6\VBE6EXT.OLB"

//Excel Application objects
#import "C:\Program Files\Microsoft Office\Office\excel.exe" \
	rename("DialogBox", "DialogBoxXL")\
	rename("RGB", "RBGXL")\
	rename("DocumentProperties", "DocumentPropertiesXL")\
	rename("ReplaceText", "ReplaceTextXL")\
	rename("CopyFile", "CopyFileXL")\
	exclude("IFont", "IPicture") no_dual_interfaces

using namespace std;
When I wrote the above code, I am getting an error

fatal error C1083: Cannot open type library file: 'c:\program files\microsoft office\office\excel.exe': Error loading type library/DLL.
Can someone please tell me what I am missing here inorder to run the code.

Thanks In Advance.