Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Controls
  New Posts New Posts RSS Feed - CXTPTaskDialog and SetResourceFile
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPTaskDialog and SetResourceFile

 Post Reply Post Reply
Author
Message
zitz View Drop Down
Senior Member
Senior Member


Joined: 05 October 2008
Status: Offline
Points: 112
Post Options Post Options   Thanks (0) Thanks(0)   Quote zitz Quote  Post ReplyReply Direct Link To This Post Topic: CXTPTaskDialog and SetResourceFile
    Posted: 16 March 2009 at 4:18am
I use Xtreme ToolkitPro v13.0.0
If load resource dll
XTPResourceManager()->SetResourceManager( new CXTPResourceManager() );
XTPResourceManager()->SetResourceFile( _T("ToolkitPro.ResourceEn.dll") );

or any other resource dll from Xtreme ToolkitPro v13.0.0\Utils\Translations
then
CXTPTaskDialog dlgMessage( this );
dlgMessage.SetWindowTitle( _T("Information") );
dlgMessage.SetMainInstruction( _T("Error") );
dlgMessage.SetMainIcon( TD_ERROR_ICON );
dlgMessage.AddButton( _T("OK", IDOK );
dlgMessage.SetDefaultButton( IDOK );
dlgMessage.EnableCancellation();
dlgMessage.DoModal();

CXTPTaskDialog is showing without icon!
ASSERT(hNewIcon != NULL);
hNewIcon = XTPResourceManager()->LoadIcon(MAKEINTRESOURCE(dwID), sizeIcon);

Please help!!!
What to do to fix this?
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


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: 16 March 2009 at 8:09am

Hi,

Do you build statically ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
zitz View Drop Down
Senior Member
Senior Member


Joined: 05 October 2008
Status: Offline
Points: 112
Post Options Post Options   Thanks (0) Thanks(0)   Quote zitz Quote  Post ReplyReply Direct Link To This Post Posted: 16 March 2009 at 8:10am
Yes, i build statically.

If i comment
//XTPResourceManager()->SetResourceFile(...
icon is show ok

Back to Top
zitz View Drop Down
Senior Member
Senior Member


Joined: 05 October 2008
Status: Offline
Points: 112
Post Options Post Options   Thanks (0) Thanks(0)   Quote zitz Quote  Post ReplyReply Direct Link To This Post Posted: 16 March 2009 at 3:27pm
I use the same code at Xtreme ToolkitPro v11.2.0 and it's work fine.
I make a multilingual application and need to localize Codejock dialogs.
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


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: 17 March 2009 at 3:23am
Thanks, I see.
 
thing that these dlls don't have binary resources by default. You can modify Workspace\Resource\ResourcePackage.h  and remove "_XTP_NO_BINARY_RESOURCES" and rebuild dlls.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
zitz View Drop Down
Senior Member
Senior Member


Joined: 05 October 2008
Status: Offline
Points: 112
Post Options Post Options   Thanks (0) Thanks(0)   Quote zitz Quote  Post ReplyReply Direct Link To This Post Posted: 18 March 2009 at 3:56am
These icons do not change depending on the language, why would they get from a language dll?
I set SetUseSysIcons( TRUE ) - it decided my problem.
Many problems can be obtained using a language dll without binary resources?
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


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: 18 March 2009 at 9:41am
Hi,
 
Seems with static build it can be problem with all binary resources. :(  Suggest to add them anyway.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
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.156 seconds.