Thread overview
[VOLE] : need help
Sep 14, 2008
Mario Lecafe
Sep 15, 2008
Matt Wilson
Sep 25, 2008
Mario Lecafe
Sep 26, 2008
Matthew Wilson
Oct 13, 2008
Mario Lecafe
Oct 15, 2008
Matthew Wilson
Sep 16, 2008
Matthew Wilson
September 14, 2008
Hello,

I want to create a C++ program COM to drive Excel (like using Perl Win32::OLE or Python

win32com.client) with the open-source C++ libraries VOLE-0.4.4/stlsoft-1.9.46

My configuration :
Windows XP and the GNU GCC 3.4.2 compiler (mingw32)

I'm trying to use the example "Excel.driver.cpp" with my compiler
 G++ -I%VOLE%/include -I%STLSOFT%/include ....

but it makes error that I can't resolve (with VOLE 0.5.1/stlsoft-1.9.48 too)

Error :

vole::object  xlApp   =   vole::object::create(L"Excel.Application",
CLSCTX_LOCAL_SERVER);

error: no matching function for call to `vole::object::create(const
wchar_t[18], tagCLSCTX)'

C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|524|note: candidates are: static vole::object

vole::object::create(const CLSID&) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|537|note: static vole::object

vole::object::create(const CLSID&, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|550|note: static vole::object

vole::object::create(const WCHAR*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|563|note: static vole::object

vole::object::create(const WCHAR*, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|577|note: static vole::object

vole::object::create(const char*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|582|note: static vole::object

vole::object::create(const char*, DWORD,
vole::coercion_level::coercion_level)


Please Help me to continue.

Another question :
Is it possible to use VOLE/stlsoft libraries with cross-compiling for win32
under linux ?

Note :
I am a C++ beginner, I'm french and my English is not good, please answer me
in simple words.


Best,

Mario




September 15, 2008
Mario Lecafe Wrote:

> Hello,
> 
> I want to create a C++ program COM to drive Excel (like using Perl Win32::OLE or Python win32com.client) with the open-source C++ libraries VOLE-0.4.4/stlsoft-1.9.46
> 
> My configuration :
> Windows XP and the GNU GCC 3.4.2 compiler (mingw32)
> 
> I'm trying to use the example "Excel.driver.cpp" with my compiler
>  G++ -I%VOLE%/include -I%STLSOFT%/include ....
> 
> but it makes error that I can't resolve (with VOLE 0.5.1/stlsoft-1.9.48 too)
> 
> Error :
> 
> vole::object  xlApp   =   vole::object::create(L"Excel.Application",
> CLSCTX_LOCAL_SERVER);
> 
> error: no matching function for call to `vole::object::create(const
> wchar_t[18], tagCLSCTX)'
> 
> C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|524|note: candidates are: static vole::object
> 
> vole::object::create(const CLSID&) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|537|note: static vole::object
> 
> vole::object::create(const CLSID&, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|550|note: static vole::object
> 
> vole::object::create(const WCHAR*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|563|note: static vole::object
> 
> vole::object::create(const WCHAR*, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|577|note: static vole::object
> 
> vole::object::create(const char*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|582|note: static vole::object
> 
> vole::object::create(const char*, DWORD,
> vole::coercion_level::coercion_level)
> 
> 
> Please Help me to continue.
> 
> Another question :
> Is it possible to use VOLE/stlsoft libraries with cross-compiling for win32
> under linux ?
> 
> Note :
> I am a C++ beginner, I'm french and my English is not good, please answer me
> in simple words.
> 
> 
> Best,
> 
> Mario

I think the problem is simply that the create() method changed to have three (non-default) arguments in version 0.2.1. Clearly I have forgotten to update the example, for which I apologise. Please look at test/scratch/Excel.driver.test.

HTH

Matt
September 16, 2008
> Another question :
> Is it possible to use VOLE/stlsoft libraries with cross-compiling for win32
> under linux ?

Yes for STLSoft
No for VOLE, because COM is a Windows-specific thing.

HTH

Matt


September 25, 2008
"Matt Wilson" <stlsoft@gmail.com> a écrit dans le message de news: galnu4$1e04$1@digitalmars.com...
> Mario Lecafe Wrote:
>
>> Hello,
>>
>> I want to create a C++ program COM to drive Excel (like using Perl Win32::OLE or Python win32com.client) with the open-source C++ libraries VOLE-0.4.4/stlsoft-1.9.46
>>
>> My configuration :
>> Windows XP and the GNU GCC 3.4.2 compiler (mingw32)
>>
>> I'm trying to use the example "Excel.driver.cpp" with my compiler
>>  G++ -I%VOLE%/include -I%STLSOFT%/include ....
>>
>> but it makes error that I can't resolve (with VOLE 0.5.1/stlsoft-1.9.48
>> too)
>>
>> Error :
>>
>> vole::object  xlApp   =   vole::object::create(L"Excel.Application",
>> CLSCTX_LOCAL_SERVER);
>>
>> error: no matching function for call to `vole::object::create(const
>> wchar_t[18], tagCLSCTX)'
>>
>> C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|524|note: candidates
>> are:
>> static vole::object
>>
>> vole::object::create(const CLSID&) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|537|note: static vole::object
>>
>> vole::object::create(const CLSID&, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|550|note: static vole::object
>>
>> vole::object::create(const WCHAR*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|563|note: static vole::object
>>
>> vole::object::create(const WCHAR*, DWORD, vole::coercion_level::coercion_level) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|577|note: static vole::object
>>
>> vole::object::create(const char*) C:\opensrc\vole\vole-0.4.4\include\vole\object.hpp|582|note: static vole::object
>>
>> vole::object::create(const char*, DWORD,
>> vole::coercion_level::coercion_level)
>>
>>
>> Please Help me to continue.
>>
>> Another question :
>> Is it possible to use VOLE/stlsoft libraries with cross-compiling for
>> win32
>> under linux ?
>>
>> Note :
>> I am a C++ beginner, I'm french and my English is not good, please answer
>> me
>> in simple words.
>>
>>
>> Best,
>>
>> Mario
>
> I think the problem is simply that the create() method changed to have three (non-default) arguments in version 0.2.1. Clearly I have forgotten to update the example, for which I apologise. Please look at test/scratch/Excel.driver.test.
>
> HTH
>
> Matt



Hello Matt,

Thank's for your answers, I have used the test/scratch/Excel.driver.test.cpp
with the good create() methode.
The errors have disappeared, but there are many others "undefined reference
to..."

I have used this command line with Dev-Cpp or MingW :
G++ -I%VOLE%/include -I%STLSOFT%/include -o myTest.exe
C:\opensrc\vole\vole-0.4.4\test\Excel.driver.test\Excel.driver.test.cpp

Can you help me again ?


Best,

Mario





September 26, 2008
<snip>

> Hello Matt,
>
> Thank's for your answers, I have used the test/scratch/Excel.driver.test.cpp
> with the good create() methode.
> The errors have disappeared, but there are many others "undefined reference
> to..."
>
> I have used this command line with Dev-Cpp or MingW :
> G++ -I%VOLE%/include -I%STLSOFT%/include -o myTest.exe
> C:\opensrc\vole\vole-0.4.4\test\Excel.driver.test\Excel.driver.test.cpp
>
> Can you help me again ?

You'll have to link to liboleaut32.a and libole32.a

I can't remember how off the top of my head, but I think if you try "g++ <... other linker options ...> -lole32 -loleaut32" it might
be all that you need.

HTH

Matt


October 13, 2008
Le 26/09/2008, Matthew Wilson a supposé :
> <snip>
>
>> Hello Matt,
>> 
>> Thank's for your answers, I have used the test/scratch/Excel.driver.test.cpp
>> with the good create() methode.
>> The errors have disappeared, but there are many others "undefined reference
>> to..."
>> 
>> I have used this command line with Dev-Cpp or MingW :
>> G++ -I%VOLE%/include -I%STLSOFT%/include -o myTest.exe
>> C:\opensrc\vole\vole-0.4.4\test\Excel.driver.test\Excel.driver.test.cpp
>> 
>> Can you help me again ?
>
> You'll have to link to liboleaut32.a and libole32.a
>
> I can't remember how off the top of my head, but I think if you try "g++ <... other linker options ...> -lole32 -loleaut32" it might be all that you need.
>
> HTH
>
> Matt

Hello Matt,

Thanks for all your answers,

I have tried the command line with the specified libraries.
I had some errors links.
After some searches on the web, I finally found another missing library (libuuid.a)

Now the command line "G++ -I%VOLE%/include -I%STLSOFT%/include -o myTest.exe C:\opensrc\vole\vole-0.4.4\test\Excel.driver.test\Excel.driver.test.cpp -lole32 -loleaut32 -luuid" compiles the example code.

Thanks again for your help


Best,

Mario


October 15, 2008
> Thanks for all your answers,
>
> I have tried the command line with the specified libraries.
> I had some errors links.
> After some searches on the web, I finally found another missing library
> (libuuid.a)
>
> Now the command line "G++ -I%VOLE%/include -I%STLSOFT%/include -o myTest.exe C:\opensrc\vole\vole-0.4.4\test\Excel.driver.test\Excel.driver.test.cpp -lole32 -loleaut32 -luuid" compiles the example code.
>
> Thanks again for your help
>
>
> Best,
>
> Mario

You're most welcome.

Matt