Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Reset Toolbar doubt?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Reset Toolbar doubt?

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


Joined: 02 May 2007
Status: Offline
Points: 164
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ashok Quote  Post ReplyReply Direct Link To This Post Topic: Reset Toolbar doubt?
    Posted: 02 November 2007 at 8:09am
Hi,
  Is it possible to find whether reset toolbar is pressed or not. I want to find whether reset toolbar is clicked because I have to implement some code if reset toolbar in the Toolbar is clicked. Please help.
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: 02 November 2007 at 10:32am
Hello,
 
You can override
void Reset(BOOL bShowWarningMessage);
method.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Ashok View Drop Down
Senior Member
Senior Member


Joined: 02 May 2007
Status: Offline
Points: 164
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ashok Quote  Post ReplyReply Direct Link To This Post Posted: 03 November 2007 at 4:47am
Hi,
  ya, I am doing that but I want to capture the state of whether user pressed the OK or CANCEL, because if cancel i have to skip my code. How can I know the state of the OK or CANCEL button pressed while reseting the toolbar.
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 November 2007 at 1:03am

Hello,

May be even better catch WM_XTP_CUSTOMIZATION_RESETTOOLBAR message in CMainFrame - it will be called only if user press Ok.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Ashok View Drop Down
Senior Member
Senior Member


Joined: 02 May 2007
Status: Offline
Points: 164
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ashok Quote  Post ReplyReply Direct Link To This Post Posted: 06 November 2007 at 4:56am
Hi,
Please send some code related to that.
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: 06 November 2007 at 6:22am
 
ON_MESSAGE(WM_XTP_CUSTOMIZATION_RESETTOOLBAR, OnResetToolBar)
...
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Ashok View Drop Down
Senior Member
Senior Member


Joined: 02 May 2007
Status: Offline
Points: 164
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ashok Quote  Post ReplyReply Direct Link To This Post Posted: 16 November 2007 at 12:38am

Hi,

I am doing the same thing what your are suggested earlier but I want to know which toolbar's (reset toolbar) I have clicked.

LRESULT JMainFrame::OnResetToolBar(WPARAM wParam, LPARAM lParam)

{

LRESULT lRet;

if(GetBarID() != IDR_STAT_TOOLBAR)return 0; -- How can I check like this, because if I clicked the reset toolbar in the IDR_STAT_TOOLBAR then only my code should work otherwise it should skip the process.

Please help.
Back to Top
Ashok View Drop Down
Senior Member
Senior Member


Joined: 02 May 2007
Status: Offline
Points: 164
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ashok Quote  Post ReplyReply Direct Link To This Post Posted: 16 November 2007 at 6:21am
Hi,
  Please look into this issue.
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: 16 November 2007 at 6:52am
Hi,
Is it so difficult to open sources and check what parameters passed ?
 
lParam is pointer to toolbar:
 
CXTPToolBar* pToolBar = (CXTPToolBar*)lParam;
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.030 seconds.