Codejock RibbonBar first tests

Re: Codejock RibbonBar first tests

Postby Antonio Linares » Mon Apr 06, 2009 8:01 am

There was a memory leak in Class TActiveX. It has been detected and fixed :-)

Next FWH build will include this fix.

In Class TActiveX this new Method has to be included:

Code: Select all  Expand view  RUN

    METHOD Destroy() INLINE ActXEnd( ::hActiveX ), Super:Destroy()          
 


And replace this module in FiveHCM.lib (Microsoft):
http://www.mediafire.com/?sharekey=414c ... 6e282a0ee8

Or this module in FiveHC.lib (Borland):
http://www.mediafire.com/?sharekey=414c ... 8114394287
regards, saludos

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

Re: Codejock RibbonBar first tests

Postby anserkk » Mon Apr 06, 2009 8:05 am

Dear Mr.Antonio,

Are you using 12.1.1 or 13.0.0 ?

I am using 12.1.1 and is working fine on PC's If I run the CodeJock Setup. I have not tried Ver 13.0.0 and shall try

Regards

Anser
User avatar
anserkk
 
Posts: 1333
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Re: Codejock RibbonBar first tests

Postby frose » Mon Apr 06, 2009 2:51 pm

Antonio,

<<I really want to know, how Lailton, Richard, or who else has discovered this know how

<You can inspect all properties, methods and events from Microsoft Word VBA: viewtopic.php?p=78087#p78087

Thank you for the tip, but IMO it's more efficient to use the Codejock help file!?

I was reflecting to the technic to catch the events of the RibbonBar, not the other things you can relative easily find in the documentation.

Here another question of this manner:
How can I handle the 'PaneClick' event which occurs when a StatusBarPane object on the StatusBar control is clicked.
Is it possible to adap the same technic as used for the RibbonBar events? If so, how?
Windows 11 Pro 22H2 22621.1848
Microsoft (R) Windows (R) Resource Compiler Version 10.0.10011.16384
Harbour 3.2.0dev (r2008190002)
FWH 23.10 x86
User avatar
frose
 
Posts: 392
Joined: Tue Mar 10, 2009 11:54 am
Location: Germany, Rietberg

Re: Codejock RibbonBar first tests

Postby anserkk » Wed Apr 08, 2009 10:20 am

Hi,

Can anybody help me to do this in FWH. As per the write up in the CodeJock site, the property CommandBarsGlobalSettings.License should be set before the CommandBarControl is initialized. In VB this is done using the Private Sub Form_Initialize()

Writeup from the site with VB 6 Sample
The licence code should be included before any controls are created, for example, in the Form_Initialize event of the main form for Visual Basic 6.0. For simplicity, the code below demonstrates how to embed the license information for the CommandBars only, you will need to do this for each control you use.

Visual Basic 6.0

Private Sub Form_Initialize()

CommandBarsGlobalSettings.License = "CommandBars Control Copyright (c) " & _
"2003-2006 Codejock Software" & vbCrLf & "PRODUCT-ID: " & _
"Codejock.CommandBars.ActiveX.v10.20" & vbCrLf & _
"VALIDATE-CODE: XXX-XXX-XXX-XXX"

End Sub


C# Sample
In the constructor for your main form, place the following code BEFORE the call to the 'InitializeComponents' method.

// Create Instance of Global Settings Class for CommandBars
XtremeCommandBars.CommandBarsGlobalSettingsClass settings = new XtremeCommandBars.CommandBarsGlobalSettingsClass();
// Now enter the first three lines of your license file
// (Note carriage return line feed '\r\n' at the end of each line)
settings.License = "CommandBars Control Copyright (c) 2003-2004 Codejock Software\r\n" +
"PRODUCT-ID: XCB-ESD-ACTX-9500\r\n" +
"VALIDATE-CODE: XXX-XXX-XXX-XXX";

This same technique must also be used for any other Codejock ActiveX controls. It also appears that this step is only necessary on the main form of the application. I have other classes stored in DLL's that also use the Codejock controls, and I was not required to set the licenses individually for each one. I guess they truly are Global Settings


But in FWH how do we access the properties of an Activex control before the following code

Code: Select all  Expand view  RUN
oAct := TActiveX():New( oWnd, "Codejock.CommandBarsFrame.12.1.1", 0, 0, 0, 0 )


Or any idea when is this control getting initialised, do the above command Initialize the control

How do I execute the below given FWH code, before Initialising the controls ? That's where I am struck
Code: Select all  Expand view  RUN
oAct:SetProp("CommandBarsGlobalSettings.License", ;
    "CommandBars Control Copyright (c) " + ;
    "2003-2006 Codejock Software" +CRLF+ "PRODUCT-ID: " + ;
    "Codejock.CommandBars.ActiveX.v10.20" + CRLF +;
    "VALIDATE-CODE: XXX-XXX-XXX-XXX"

I understand that, If you need to use CodeJock Controls in your FWH application and then distribute the application to your clients, then this process has to be done ie the Licence code should be hard coded in our FWH application.

Do Anybody here has used CodeJock control along with FWH and done the distributions to clients.

Regards

Anser
User avatar
anserkk
 
Posts: 1333
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Re: Codejock RibbonBar first tests

Postby richard-service » Thu Apr 16, 2009 7:22 am

Hi All,

This is a Ribbonbar+Calendar simple screen shot.

Image

Image

Please visit my Ribbonbar sample code and add these lines.

Code: Select all  Expand view  RUN

local oAct2

        oAct2 := TActiveX():New( oWnd, "Codejock.CalendarControl.12.1.1", 150, 0, 1000, 550 )
 



Richard
Best Regards,

Richard

Harbour 3.2.0dev (r2402101027) => Borland C++ v7.7 32bit
MySQL v8.0 /ADS v10
Harbour 3.2.0dev (r2011030937) => Borland C++ v7.4 64bit
User avatar
richard-service
 
Posts: 804
Joined: Tue Oct 16, 2007 8:57 am
Location: New Taipei City, Taiwan

Re: Codejock RibbonBar first tests

Postby Antonio Linares » Thu Apr 16, 2009 7:29 am

Anser,

You may try:
Code: Select all  Expand view  RUN

oSettings = oAct:GetProp( "CommandBarsGlobalSettings" ) // it returns an OleAuto object

oSettings:License = "CommandBars Control Copyright (c) " + ;
    "2003-2006 Codejock Software" +CRLF+ "PRODUCT-ID: " + ;
    "Codejock.CommandBars.ActiveX.v10.20" + CRLF +;
    "VALIDATE-CODE: XXX-XXX-XXX-XXX"
 
regards, saludos

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

Re: Codejock RibbonBar first tests

Postby Antonio Linares » Thu Apr 16, 2009 7:30 am

Richard,

local oAct2

oAct2 := TActiveX():New( oWnd, "Codejock.CalendarControl.12.1.1", 150, 0, 1000, 550 )

Thanks :-)
regards, saludos

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

Re: Codejock RibbonBar first tests

Postby Cgallegoa » Fri Apr 17, 2009 5:39 pm

Antonio,

oSettings = oAct:GetProp( "CommandBarsGlobalSettings" ) // it returns an OleAuto object


Doesn´'t work.

[errsysw.prg->ERRORDIALOG] (78) Called from:
errsysw.prg->(b)ERRORSYS(49)
win32ole.prg->TOLEAUTO:COMMANDBARSGLOBALSETTINGS(0)
->__OBJSENDMSG(0)
->ACTXGETPROPERTY(0)
.\source\classes\ACTIVEX.PRG->(b)TACTIVEX:TACTIVEX(0)
->TACTIVEX:GETPROP(0)
MSTMASIV.prg->MAIN(211)
Type: C >>>COMMANDBARSGLOBALSETTINGS<<<
Type: C >>>DISP_E_PARAMNOTOPTIONAL<<<
Type: N >>> 0<<<

Regards,

Carlos Gallego
Saludos,

Carlos Gallego

*** FWH-24.07, xHarbour 1.3.1 Build 20240624, Borland C++7.70, PellesC ***
Cgallegoa
 
Posts: 494
Joined: Sun Oct 16, 2005 3:32 am
Location: Quito - Ecuador

Re: Codejock RibbonBar first tests

Postby Antonio Linares » Fri Apr 17, 2009 9:27 pm

Carlos,

This way we can access the GlobalSettings of the CommandBars:
Code: Select all  Expand view  RUN

   oSettings = oActiveX : GetProp( "GlobalSettings" )
   MsgInfo( oSettings:Version )
 
regards, saludos

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

Re: Codejock RibbonBar first tests

Postby anserkk » Tue Apr 28, 2009 7:47 am

Hi,

Has anybody here used CodeJock in your FWH app. and distributed it in your client PC's. I still have not found a solution to activate the licence through code. ( For the time being, it is working, if I distribute the .lic license file along with the OCX control. Thanks to Mr.Natter) But using VB and other prog.lang we can access the members of the control even before the control is initialised. I don't know how to do that using FWH.

It appears that the problem I'm having is that you can't access the public members of CommandBars until after the control is fully initialized. Trying to access them before full initialization throws an error. However, when you finalize the control, it looks for the license. It appears I'm stuck! I can't set the license before initialization without throwing an error, and I can't initialize the control without a license.

Regards
Anser
User avatar
anserkk
 
Posts: 1333
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Re: Codejock RibbonBar first tests

Postby Loach » Wed Apr 29, 2009 11:21 am

Hello!
Anser, may be it's not a good solution, but if in the begining of example "ribonbar.prg" insert this:
Code: Select all  Expand view  RUN

   oText := TTxtFile():New( "Codejock.CommandBars.v12.1.1.lic" )
   if oText:Open()
      oText:Add( "CommandBars Control Copyright (c) 2003-2008 Codejock Software" )
      oText:Add( "PRODUCT-ID: Codejock.CommandBars.ActiveX.v12.1" )
      oText:Add( "VALIDATE-CODE: XXX-XXX-XXX-XXX" )
      oText:Close()
   endif
 

and then after all controls defining
Code: Select all  Expand view  RUN

   ACTIVATE WINDOW oWnd ON init(ferase("Codejock.CommandBars.v12.1.1.lic"))
 

it seems, that everithing work fine...
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Loach
 
Posts: 41
Joined: Thu Dec 22, 2005 7:39 am
Location: Gomel, Belarus

Re: Codejock RibbonBar first tests

Postby anserkk » Wed Apr 29, 2009 1:08 pm

Mr.Sergey,

Thankyou for this bright idea. I think this is the only solution as of now. I don't know whether it is the limitation of Harbour/xHarbour

Regards
Anser
User avatar
anserkk
 
Posts: 1333
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Re: Codejock RibbonBar first tests

Postby RAMESHBABU » Fri May 01, 2009 5:04 am

Hi Friends,

Has anybody tried Office2003 theme in Codejock ? If so, please guide me how to do it.

Thanks,

- Ramesh Babu P
User avatar
RAMESHBABU
 
Posts: 625
Joined: Fri Oct 21, 2005 5:54 am
Location: Secunderabad (T.S), India

Re: Codejock RibbonBar first tests

Postby Sakis » Fri May 08, 2009 10:16 am

To have acess to the CommandBarsGlobalSettings on Form Initialize Event add the following code:
Code: Select all  Expand view  RUN


    LOCAL GLOBALSettings:= NIL
      GlobalSettings:= CreateObject("Codejock.CommandbarsGlobalSettings.13.0.0")
       WiTH OBJECT GlobalSettings
          :License:= "CommandBars Control Copyright (c) " + ;
          "2003-2006 Codejock Software" +CRLF+ "PRODUCT-ID: " + ;
          "XCB-ESD-ACTX-9600" + CRLF + "VALIDATE-CODE: XXX-XXX-XXX-XXX"
       END WITH
 

You will need to provide the correct Product Id and Validate Code. This information can be found in the LIC file.
This code must be added BEFORE OBJECT INITIALIZATION

:lol: Best Regards
Dionisis
User avatar
Sakis
 
Posts: 42
Joined: Fri Oct 21, 2005 2:12 pm
Location: Athens

Re: Codejock RibbonBar first tests

Postby anserkk » Sat May 09, 2009 5:29 am

Mr.Dionisis,

Thank you very much. It is working perfectly.

Regards

Anser
User avatar
anserkk
 
Posts: 1333
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

PreviousNext

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 37 guests