Print Page | Close Window

CodeJock Configuration problem.

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=4928
Printed Date: 06 October 2024 at 12:16pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: CodeJock Configuration problem.
Posted By: Sstar9
Subject: CodeJock Configuration problem.
Date Posted: 30 August 2006 at 10:18pm
I just purchased CodeJock
 
Xtreme CommandBarPro 10.30. 
Xtreme Controls 10.30
 
I want to use them in my program. I added a
 
            CXTPControlPopupColor 
 
button to my toolbar that has a child PopUp Color selector.  Hence in my OnCreateControl(*)
 
I put the codes below which are similar to the TearOff Popup bar example.  I have no problem to build and run the program. But I found, when the TearOff Color Popup bar shows, The captions "Automatic" and "More Color" do not show.  I select either the constant XTP_IDS_AUTOMATIC or XTP_IDS_MORE_COLORS in my MFC 6.0 program, right click to see the definition of the constant.  It leads me to my program's "Resource.h" page where the two constants are not defined there.  But if I want to see the definition of XTP_IDS_AUTOMATIC or XTP_IDS_MORE_COLORS in the TearOff toolbar example, it leads me to  "....\CommandBars\Resource.h" and the two constants are defined there.
 
So quite obviously "....\CommandBars\Resource.h" has not been included in my program. This should be program configuration problem.  I have included both headers in my "stdafx.h"
 
                   #include <XTCommandBarsPro.h> 
                   #include <XTControls.h>  
 
What else I should do? Any suggestions?  I am using MFC as a static library.
 
......
 
  if (lpCreateControl->nID == ID_INKCOLOR && pToolBar->GetBarID() == IDR_TOOLBAR_JW)
  {
   CXTPControlPopupColor* pPopupColor = new CXTPControlPopupColor();
   pColorBar = CXTPPopupToolBar::CreatePopupToolBar(GetCommandBars());
   pPopupColor->SetCommandBar(pColorBar);
   CXTPControl * pXTPCtrl =
    pColorBar->GetControls()->Add(new CXTPControlButtonColor(), XTP_IDS_AUTOMATIC);
   pColorBar->GetControls()->Add(new CXTPControlColorSelector(), ID_SELECTOR_TEXT);
   pXTPCtrl =
    pColorBar->GetControls()->Add(new CXTPControlButtonColor(), XTP_IDS_MORE_COLORS);
   pColorBar->SetTearOffPopup(_T("Ink Color"), 1005, 0);
   pColorBar->EnableCustomization(FALSE);
   pColorBar->InternalRelease();
   lpCreateControl->pControl = pPopupColor;
   return TRUE;
  }
......
 
 


-------------
Sharing makes life better



Replies:
Posted By: Oleg
Date Posted: 31 August 2006 at 8:41am
Hi,
Check, maybe in your resource.h you added this constants?


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Sstar9
Date Posted: 01 September 2006 at 12:43am

Adding the constants in my "Resource.h" does not work. But anyway, I found out the reason for this.  The reason is I set "Using MFC as Static Library". This could be reproduced with codejock's own sample applications. If I am not wrong, it seems applications which Use MFC as Static Library are not well-supported with CodeJock Library.  



-------------
Sharing makes life better


Posted By: Oleg
Date Posted: 01 September 2006 at 11:55am
Supported.
But If you use MFC as static library, codejock linked as static too and you have manually to add resources to rc2 file.
 
in your res\[app].rc2  add
 
#include <XTToolkitPro.rc>
 
and all will work.
 


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



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