FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Harbour Ole error
Posts: 1096
Joined: Fri Oct 28, 2005 02:27 AM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 07:37 AM
Maurizio,
This is just pure hunch but could you test with oPdfApp:AutoSaveDirectory := "C:\TEMP"
FWH 11.08/FWH 19.12

BCC5.82/BCC7.3

xHarbour/Harbour
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 08:11 AM
Antonio Linares wrote:Richard,

Przemek talked (in his usual style :-) )


That attitude is exactly the reason why I dropped Harbour.

EMG
Posts: 946
Joined: Thu Oct 06, 2005 07:05 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 08:17 AM
Antonio

it is working with xharbour since 2 years

oevent:CustomProperties:Property( "id", cid ) this is the xharbour syntax

with this we set the property of ("id") to the value CID

In theory wirh Harbour we should write oevent:CustomProperties:Property( "id") = cid but the compiler does not allow..

at the moment i have no way of doing the same in harbour

still searching for an alternative way , unfortunately this information (event id) is the key of all the control....

Thanks for help,

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 08:21 AM

Richard,

What error do you get with this in Harbour ?

oevent:CustomProperties:Property( "id", cid )

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 946
Joined: Thu Oct 06, 2005 07:05 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 08:26 AM

Antonio

This is the error

Error description: (DOS Error -2147352562) WINOLE/1007 Argument error: PROPERTY
Args:
[ 1] = C id
[ 2] = C 000000000342

Stack Calls

Called from: => TOLEAUTO:PROPERTY( 0 )

Richard

http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
Posts: 368
Joined: Sun May 31, 2009 06:25 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 11:41 AM
Richard,

Have a try this way:

Code (fw): Select all Collapse
oevent:CustomProperties:id := CID
Regards,



André Dutheil

FWH 13.04 + HB 3.2 + MSVS 10
Posts: 946
Joined: Thu Oct 06, 2005 07:05 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 12:27 PM

I had tried it , it does not work

Error description: (DOS Error -2147352570) WINOLE/1008 No exported variable: ID
Args:
[ 1] = C 000000000342

it really is looking for the properties of "id"

Thanks for the suggestion,

http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
Posts: 337
Joined: Fri Oct 07, 2005 02:44 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 12:35 PM

Hello,

This doc is in olecore.c in harbour/contrib/hbwin :


VBScript and Harbour syntax and IDispatch:Invoke() usage differences

VBScript syntax dispid DISPATCH_* flags argcnt | Harbour syntax :Invoke parameters
================================================================+=======================================
obj DISPID_VALUE METHOD+PROPERTYGET 0 | Same :Invoke is not used
obj() DISPID_VALUE METHOD 0 | Not supported
obj(param) DISPID_VALUE METHOD+PROPERTYGET 1 | obj[param] Same
obj.name name METHOD+PROPERTYGET 0 | Same, =obj.name() Same
obj.name() name METHOD 0 | Same, =obj.name flags=METHOD+PROPERTYGET
obj.name(param) name METHOD+PROPERTYGET 1 | Same Same
|
obj = value obj reassigned, :Invoke is not used | Same
obj() = value DISPID_VALUE PROPERTYPUT 1 | Not supported
obj(param) = value DISPID_VALUE PROPERTYPUT 2 | obj[param] = value
obj.name = value name PROPERTYPUT 1 | Same Same
obj.name() = value name PROPERTYPUT 1 | Not supported, use obj.name = value
obj.name(param) = value name PROPERTYPUT 2 | Not supported, workaround obj._name(param, value)


bye,

Lautaro

Hola,

Soy un Contador que por necesidad aprendio a programar y se quedo programando.
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 12:50 PM
Richard,

Have you tried this ?

obj.name(param) = value name PROPERTYPUT 2 | Not supported, workaround obj._name(param, value)


this one: Notice the "_"
obj:_name(param, value)
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 842
Joined: Mon Oct 10, 2005 01:29 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 01:00 PM

obj.name(param) = value name PROPERTYPUT 2 | Not supported, workaround obj._name(param, value)

In effects

I found this in : C:\Harbour\contrib\hbwin\tests\pdfcreat.prg

with Harbour
oPC:_cOption( "AutosaveDirectory", "c:\temp" )
oPC:_cOption( "AutosaveFilename", "pdfcreat.pdf" )

with xHarbour
oPC:cOption( "AutosaveDirectory", "c:\temp" )
oPC:cOption( "AutosaveFilename", "pdfcreat.pdf" )

Maurizio

:?:

Posts: 946
Joined: Thu Oct 06, 2005 07:05 PM
Re: Harbour Ole error
Posted: Wed Apr 17, 2013 01:05 PM
Lautaro

Thanks a lot, now i have it working

the correct syntax is

oevent:customproperties:_Property("id",CID)

Thanks to all who helped and a big thank to Antonio as usual :-)

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013

Continue the discussion