Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - I met problem in CXTCaption::Create()
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

I met problem in CXTCaption::Create()

 Post Reply Post Reply
Author
Message
ksiva View Drop Down
Newbie
Newbie
Avatar

Joined: 04 August 2005
Location: Russian Federation
Status: Offline
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote ksiva Quote  Post ReplyReply Direct Link To This Post Topic: I met problem in CXTCaption::Create()
    Posted: 05 August 2005 at 2:43pm
Method CXTCaption::Create() has next code
 
if (HasCloseButton())
{
  // Create the caption's close button.
  if (!m_btnCaption.Create(NULL, WS_VISIBLE|WS_CHILD|BS_ICON|BS_OWNERDRAW|BS_CENTER|BS_VCENTE R,
    CRect(0,0,0,0), this, XT_IDC_BTN_CLOSE))
  {
    TRACE0( "Unable to create caption button.\n" );
    return -1;
  }
  // Create the image list used by frame buttons.
  m_ilButton.Create (XT_IDB_BTN_OUT, 16, 1, RGB(255,0,255));
  // and set the icon for the caption's close button
  m_btnCaption.SetIcon( CSize( 16, 15 ), m_ilButton.ExtractIcon( 2 ) );
}
 

I have problem in m_ilButton.ExtractIcon() because it doesn't check result from m_ilButton.Create() and if it is false then m_ilButton.ExtractIcon( ) fails.
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 05 August 2005 at 11:16pm

If Create fails, that mean you have no codejock resource in your exe/dll

I guess you build Application with Statically Toolkit? If so, add "XTToolkitPro.rc" in rc2 files.

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
ksiva View Drop Down
Newbie
Newbie
Avatar

Joined: 04 August 2005
Location: Russian Federation
Status: Offline
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote ksiva Quote  Post ReplyReply Direct Link To This Post Posted: 08 August 2005 at 9:55am
Yes. Thanks. You are genius.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.031 seconds.