Author | Topic: Method isInstalled always returns FALSE in Xbase 2.0 | |
---|---|---|
R.M. Meijer | Method isInstalled always returns FALSE in Xbase 2.0 on Mon, 09 May 2016 16:32:49 +0200 Met vriendelijke groet, With kind regards, Rens Zwanenburg | |
Chris Chambers | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Mon, 09 May 2016 14:34:54 -0700 On 5/9/2016 7:32 AM, R.M. Meijer wrote: > Hi, > > Within an XBase 2.0 application I call > AutomationObject():isInstalled(CLSID) and I always get *.F.* as return > value? > > _Sample:_ > AutomationObject():isInstalled("TIS.TX.TextControl.19") > > With XBase 1.9 this method works fine! > > > -- > Met vriendelijke groet, > With kind regards, > > Rens Zwanenburg > Hi, Is the active X control properly registered, if you are using two different machines for 1.9 and 2.0 Regards Chris | |
R.M. Meijer | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Wed, 11 May 2016 09:16:41 +0200 Met vriendelijke groet, With kind regards, Rens Zwanenburg Op 9-5-2016 om 23:34 schreef Chris Chambers: > On 5/9/2016 7:32 AM, R.M. Meijer wrote: >> Hi, >> >> Within an XBase 2.0 application I call >> AutomationObject():isInstalled(CLSID) and I always get *.F.* as return >> value? >> >> _Sample:_ >> AutomationObject():isInstalled("TIS.TX.TextControl.19") >> >> With XBase 1.9 this method works fine! >> >> >> -- >> Met vriendelijke groet, >> With kind regards, >> >> Rens Zwanenburg >> > > Hi, > Is the active X control properly registered, if you are using two > different machines for 1.9 and 2.0 > Regards > Chris | |
R.M. Meijer | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Wed, 11 May 2016 09:24:43 +0200 Met vriendelijke groet, With kind regards, Rens Zwanenburg Op 11-5-2016 om 9:16 schreef R.M. Meijer: > > Hi Chris, > > I tested this on a single machine (Win7 pro), I build two versions of > the same application (with both xBase 1.9 and xBase 2.0 environments). > > When I start the 1.9 version everything works just fine (return value > from :isInstalled() == .T.); but when I start the 2.0 version the > return value is always .F. ?? > > -- > Met vriendelijke groet, > With kind regards, > > Rens Zwanenburg > Op 9-5-2016 om 23:34 schreef Chris Chambers: >> On 5/9/2016 7:32 AM, R.M. Meijer wrote: >>> Hi, >>> >>> Within an XBase 2.0 application I call >>> AutomationObject():isInstalled(CLSID) and I always get *.F.* as return >>> value? >>> >>> _Sample:_ >>> AutomationObject():isInstalled("TIS.TX.TextControl.19") >>> >>> With XBase 1.9 this method works fine! >>> >>> >>> -- >>> Met vriendelijke groet, >>> With kind regards, >>> >>> Rens Zwanenburg >>> >> >> Hi, >> Is the active X control properly registered, if you are using two >> different machines for 1.9 and 2.0 >> Regards >> Chris > | |
Chris Chambers | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Fri, 13 May 2016 05:46:16 -0700 On 5/11/2016 12:24 AM, R.M. Meijer wrote: > I just found PDR 6739 which describes exactly my problem: > > *Symptom: * > AutomationObject:IsInstall() returns wrong value > *Description: * > > Using Xbase++ 2.0 the class method > AutomationObject():isInstalled( cProgId | cClassId ) > does not properly detect a COM/AcitveX object when a ProgId was passed as > parameter. > > *Solution: * > > Append the ProgId with Chr(0) as shown in the code below: > > ========================== snip =========================== > #pragma library( "ascom10.lib" ) > PROCEDURE Main() > LOCAL cProgId := "Word.Application" > > #define WORKAROUND_6739 > #ifdef WORKAROUND_6739 > cProgId += Chr(0) > #endif > > ? AutomationObject():IsInstalled( cProgId ) > > RETURN > ========================== snap =========================== > > > > -- > Met vriendelijke groet, > With kind regards, > > Rens Zwanenburg > > Op 11-5-2016 om 9:16 schreef R.M. Meijer: >> >> Hi Chris, >> >> I tested this on a single machine (Win7 pro), I build two versions of >> the same application (with both xBase 1.9 and xBase 2.0 environments). >> >> When I start the 1.9 version everything works just fine (return value >> from :isInstalled() == .T.); but when I start the 2.0 version the >> return value is always .F. ?? >> >> -- >> Met vriendelijke groet, >> With kind regards, >> >> Rens Zwanenburg >> Op 9-5-2016 om 23:34 schreef Chris Chambers: >>> On 5/9/2016 7:32 AM, R.M. Meijer wrote: >>>> Hi, >>>> >>>> Within an XBase 2.0 application I call >>>> AutomationObject():isInstalled(CLSID) and I always get *.F.* as return >>>> value? >>>> >>>> _Sample:_ >>>> AutomationObject():isInstalled("TIS.TX.TextControl.19") >>>> >>>> With XBase 1.9 this method works fine! >>>> >>>> >>>> -- >>>> Met vriendelijke groet, >>>> With kind regards, >>>> >>>> Rens Zwanenburg >>>> >>> >>> Hi, >>> Is the active X control properly registered, if you are using two >>> different machines for 1.9 and 2.0 >>> Regards >>> Chris >> > Does it work for you now? Regards Chris | |
R.M. Meijer | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Wed, 18 May 2016 10:14:08 +0200 Met vriendelijke groet, With kind regards, Rens Zwanenburg Op 13-5-2016 om 14:46 schreef Chris Chambers: > On 5/11/2016 12:24 AM, R.M. Meijer wrote: >> I just found PDR 6739 which describes exactly my problem: >> >> *Symptom: * >> AutomationObject:IsInstall() returns wrong value >> *Description: * >> >> Using Xbase++ 2.0 the class method >> AutomationObject():isInstalled( cProgId | cClassId ) >> does not properly detect a COM/AcitveX object when a ProgId was >> passed as >> parameter. >> >> *Solution: * >> >> Append the ProgId with Chr(0) as shown in the code below: >> >> ========================== snip =========================== >> #pragma library( "ascom10.lib" ) >> PROCEDURE Main() >> LOCAL cProgId := "Word.Application" >> >> #define WORKAROUND_6739 >> #ifdef WORKAROUND_6739 >> cProgId += Chr(0) >> #endif >> >> ? AutomationObject():IsInstalled( cProgId ) >> >> RETURN >> ========================== snap =========================== >> >> >> >> -- >> Met vriendelijke groet, >> With kind regards, >> >> Rens Zwanenburg >> >> Op 11-5-2016 om 9:16 schreef R.M. Meijer: >>> >>> Hi Chris, >>> >>> I tested this on a single machine (Win7 pro), I build two versions of >>> the same application (with both xBase 1.9 and xBase 2.0 environments). >>> >>> When I start the 1.9 version everything works just fine (return value >>> from :isInstalled() == .T.); but when I start the 2.0 version the >>> return value is always .F. ?? >>> >>> -- >>> Met vriendelijke groet, >>> With kind regards, >>> >>> Rens Zwanenburg >>> Op 9-5-2016 om 23:34 schreef Chris Chambers: >>>> On 5/9/2016 7:32 AM, R.M. Meijer wrote: >>>>> Hi, >>>>> >>>>> Within an XBase 2.0 application I call >>>>> AutomationObject():isInstalled(CLSID) and I always get *.F.* as >>>>> return >>>>> value? >>>>> >>>>> _Sample:_ >>>>> AutomationObject():isInstalled("TIS.TX.TextControl.19") >>>>> >>>>> With XBase 1.9 this method works fine! >>>>> >>>>> >>>>> -- >>>>> Met vriendelijke groet, >>>>> With kind regards, >>>>> >>>>> Rens Zwanenburg >>>>> >>>> >>>> Hi, >>>> Is the active X control properly registered, if you are using two >>>> different machines for 1.9 and 2.0 >>>> Regards >>>> Chris >>> >> > Does it work for you now? > Regards > Chris > | |
Andreas Gehrs-Pahl | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Wed, 18 May 2016 07:11:56 -0400 Rens, >#ifdef XB20 workaround (PDR 6739) >When I compile with XBase 2.0, I define _XB20_, so the 'Chr(0)' gets added. You could simply use the built-in define constant XPPVER in your code, which could look something like this: #if XPPVER > 2000000 workaround (PDR 6739) That way, you don't have to create a new define constant. Instead of version 2000000, you could be even more specific, and use 2000482, as most changes, like new Function Names, etc., were introduced in build 2.00.483. Hope that helps, Andreas Andreas Gehrs-Pahl Absolute Software, LLC phone: (989) 723-9927 email: Andreas@AbsoluteSoftwareLLC.com web: http://www.AbsoluteSoftwareLLC.com [F]: https://www.facebook.com/AbsoluteSoftwareLLC | |
R.M. Meijer | Re: Method isInstalled always returns FALSE in Xbase 2.0 on Thu, 19 May 2016 09:33:58 +0200 Rens Zwanenburg Op 18-5-2016 om 13:11 schreef Andreas Gehrs-Pahl: > Rens, > >> #ifdef _XB20_ // workaround (PDR 6739) >> When I compile with XBase 2.0, I define _XB20_, so the 'Chr(0)' gets added. > You could simply use the built-in define constant XPPVER in your code, which > could look something like this: > > #if XPPVER > 2000000 // workaround (PDR 6739) > > That way, you don't have to create a new define constant. Instead of version > 2000000, you could be even more specific, and use 2000482, as most changes, > like new Function Names, etc., were introduced in build 2.00.483. > > Hope that helps, > > Andreas |