Print Page | Close Window

ActiveX and Xbase Languages

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: ActiveX COM
Forum Description: Topics related to Codejock ActiveX COM products
URL: http://forum.codejock.com/forum_posts.asp?TID=14221
Printed Date: 21 November 2024 at 8:07pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: ActiveX and Xbase Languages
Posted By: sakissv
Subject: ActiveX and Xbase Languages
Date Posted: 05 May 2009 at 12:04pm

Hello to all

I intend to include your marveless controls into my xBase (Xailer IDE) programs. The main problem is, i can
not have access to CalendarGlobalSettings Class. All other classes methotds and events are ok. Is there
another way to have access to the above properties. Curently using for tests your Ver 13.0 Demo on
Vista Ultimate 32-bit with SP1 and Xailer (xBase Compatible) IDE for writing my programs.
Is there on your plans to use an external file (XML,INI etc) to pass these parameters, it is an easy
and clear way and i think is easy to implemented. 
 
Any help would be apreciate
TIA
Dionisis



Replies:
Posted By: Auge_Ohr
Date Posted: 27 May 2009 at 10:42pm
Originally posted by sakissv sakissv wrote:

The main problem is, i cannot have access to CalendarGlobalSettings Class.
CalendarGlobalSettings Class does have there own CLSID
FUNCTION TestCJCalendar( nMode )
LOCAL oCal, oDialogs, oResource, oResources, oResourceManager, oDPTheme, oCalTheme

#IFDEF MYOCX
   LOCAL cLicCalendar := ;
         "Calendar Control Copyright (c) 2003-2009 Codejock Software"+ Chr(13)+Chr(10) +;
         "PRODUCT-ID: Codejock.Calendar.ActiveX.v13.0"+ Chr(13)+Chr(10) +;
         "VALIDATE-CODE: xxx-xxx-xxx-xxx"
   LOCAL cVer                :=  "13.0.0"
   LOCAL cPathActiveX        :=  "C:\Programme\Codejock Software\ActiveX\Xtreme SuitePro ActiveX v13.0.0 (30 Day Trial)\Bin\"

#ELSE
   LOCAL cLicCalendar        := ;
         'Calendar Control Copyright (c) 2003-2007 Codejock Software' +CCRLF+;
         'PRODUCT-ID: Codejock.Calendar.ActiveX.v11.2' +CCRLF+;
         'VALIDATE-CODE: zzz-zzz-zzz-zzz'
   LOCAL cVer                := '11.2.2'
   LOCAL cPathActiveX        :=  "C:\Creative.acp\ActiveX\"

#ENDIF

   LOCAL ClsCalTheme2007     :=  "Codejock.CalendarThemeOffice2007"   +'.'+ cVer
   LOCAL ClsGlobalSettings   :=  "Codejock.CalendarGlobalSettings"    +'.'+ cVer
   LOCAL ClsDialogs          :=  "Codejock.CalendarDialogs"           +'.'+ cVer
   LOCAL ClsDatePicker       :=  "Codejock.DatePicker"                +'.'+ cVer
   LOCAL ClsDPTheme2007      :=  "Codejock.DatePickerThemeOffice2007" +'.'+ cVer
   LOCAL ClsResource         :=  "Codejock.CalendarResource"          +'.'+ cVer
   LOCAL ClsResources        :=  "Codejock.CalendarResources"         +'.'+ cVer
   LOCAL ClsResourceManager  :=  "Codejock.CalendarResourcesManager"  +'.'+ cVer

   #IFDEF __XPP__
   #ELSE
   LOCAL oThread := Thread():new()

   //
   oCal := V32CodeJockPro():New( 'Calendar', cVer, cPathActiveX, cLicCalendar )
   oCal:lRegister := .t.
   oCal:Create()
   if !( oCal:lCreated )
      RETURN  nil
   ENDIF
   //
   #ENDIF

   // Create Objects in the main thread
   //
   oDialogs         := CreateObject( ClsDialogs         )
   oDPTheme         := CreateObject( ClsDPTheme2007     )
   oCalTheme        := CreateObject( ClsCalTheme2007    )
   oResources       := CreateObject( ClsResources       )
   oResourceManager := CreateObject( ClsResourceManager )

   #if 0
   // This can be created in the fired thread
   oResource        := CreateObject( ClsResource        )
   #endif

   if nMode == 0

      #IFDEF __XPP__
         CJMyCalendar( oDialogs, oResource, oResources, oResourceManager, oDPTheme, oCalTheme, cLicCalendar, 0 )
      #ELSE
         oThread:start( "CJMyCalendar", oDialogs, oResource, oResources, oResourceManager, oDPTheme, oCalTheme, cLicCalendar, 0  )
      #ENDIF

   ELSE
      // Threaded Resources do not work in H... ! May be oResources oNly accepts main thread.
      //
      //oThread:start( "CJMyCalendar", oDialogs, oResource, oResources, oResourceManager, oDPTheme, oCalTheme, cLicCalendar, 1  )
      //
      CJMyCalendar( oDialogs, oResource, oResources, oResourceManager, oDPTheme, oCalTheme, cLicCalendar, 1 )
   endif

   RETURN nil
i guess you use harbour so all with #IFDEF __XPP__ (Xbase++) is obsolet for you


-------------
greetings by OHR
Jimmy


Posted By: sakissv
Date Posted: 29 May 2009 at 11:59am
Hello Jimmy
 
Many thanks for your answer. i solve the problem  with this kind of code:
 
METHOD FormInitialize( oSender ) CLASS TForm1
   LOCAL GLOBALSettings:= NIL
   SetLanguage(26)
   GlobalSettings:= CreateObject("Codejock.CalendarGlobalSettings.13.0.0")
   WITH OBJECT GlobalSettings
     :License:="Calendar Control Copyright (c) 2003-2009 Codejock Software"+CRLF+;
      "PRODUCT-ID: Codejock.Calendar.ActiveX.v13.0"+CRLF+;
      "VALIDATE-CODE: XXX-XXX-XXX-XXX"
     :ResourceFile:= Application:cDirectory+"SuitePro.ResourceEl.dll"
     :UseResourceFileLocale:=.T.
     MsgInfo(:License)
   END WITH
 
RETURN NIL
 
For my programs i use Xailer+ xHarbour.
 
Best Regards
Dionisis



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net