Harbour Ole error

Re: Harbour Ole error

Postby hua » Wed Apr 17, 2013 7:37 am

Maurizio,
This is just pure hunch but could you test with oPdfApp:cOption:AutoSaveDirectory := "C:\TEMP"
FWH 11.08/FWH 19.12
BCC5.82/BCC7.3
xHarbour/Harbour
hua
 
Posts: 1072
Joined: Fri Oct 28, 2005 2:27 am

Re: Harbour Ole error

Postby Enrico Maria Giordano » Wed Apr 17, 2013 8:11 am

Antonio Linares wrote:Richard,

Przemek talked (in his usual style :-) )


That attitude is exactly the reason why I dropped Harbour.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Harbour Ole error

Postby Richard Chidiak » Wed Apr 17, 2013 8: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
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Re: Harbour Ole error

Postby Antonio Linares » Wed Apr 17, 2013 8:21 am

Richard,

What error do you get with this in Harbour ?

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

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Harbour Ole error

Postby Richard Chidiak » Wed Apr 17, 2013 8: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
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Re: Harbour Ole error

Postby ADutheil » Wed Apr 17, 2013 11:41 am

Richard,

Have a try this way:

Code: Select all  Expand view
oevent:CustomProperties:id := CID
Regards,

André Dutheil
FWH 13.04 + HB 3.2 + MSVS 10
ADutheil
 
Posts: 368
Joined: Sun May 31, 2009 6:25 pm
Location: Salvador - Bahia - Brazil

Re: Harbour Ole error

Postby Richard Chidiak » 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
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Re: Harbour Ole error

Postby Lautaro » 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
User avatar
Lautaro
 
Posts: 322
Joined: Fri Oct 07, 2005 2:44 pm
Location: Osorno, Chile

Re: Harbour Ole error

Postby Antonio Linares » 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
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Harbour Ole error

Postby Maurizio » Wed Apr 17, 2013 1: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
User avatar
Maurizio
 
Posts: 824
Joined: Mon Oct 10, 2005 1:29 pm

Re: Harbour Ole error

Postby Richard Chidiak » Wed Apr 17, 2013 1: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 :D

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
User avatar
Richard Chidiak
 
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 37 guests