Print Page | Close Window

How can I set OnLButtonUp for cell?

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=6047
Printed Date: 22 November 2024 at 3:02am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: How can I set OnLButtonUp for cell?
Posted By: andrey
Subject: How can I set OnLButtonUp for cell?
Date Posted: 09 January 2007 at 9:24am
 
 
I derived from CXTPReportControl and Report Row classes and owerwrote virtual functoins

CXTPReportControl::CreateRow()

and

CXTPReportRow ::OnLButtonDown

 

But there is no virtual CXTPReportRow ::OnLButtonUp

How can I set OnLButtonUp for a cell, or just for control. Is it possible?



Replies:
Posted By: sserge
Date Posted: 11 January 2007 at 6:20pm
You can use CXTPReportRow::OnClick
 
Or Create derived class and add message handler ON_WM_LBUTTONUP()
 
See Also implementation of CXTPReportControl::OnLButtonUp

--
WBR,
Serge


Posted By: TerryT
Date Posted: 12 February 2007 at 1:03pm

Hi Serge,
I have a class derived from CXTPReportView, and get all messages in the map below except for ON_WM_LBUTTONUP()

I’m attempting to detect a click off of any of the report items so I can remove focus/highlighting of the selected report row – ie, a click on the whitespace below the report items.

Please advise…
Thank you!

BEGIN_MESSAGE_MAP(CTaskListView, CXTPReportView)
 ON_WM_CREATE()
 ON_WM_SIZE()
 ON_COMMAND(ID_ADD_TASK, OnAddTask)
 ON_COMMAND(ID_REMOVE_TASK, OnRemoveTask)
 ON_UPDATE_COMMAND_UI(ID_ADD_TASK, OnUpdateAddTask)
 ON_UPDATE_COMMAND_UI(ID_REMOVE_TASK, OnUpdateRemoveTask)
 ON_NOTIFY(XTP_NM_REPORT_INPLACEBUTTONDOWN, XTP_ID_REPORT_CONTROL, OnReportButtonClick)
 ON_NOTIFY(XTP_NM_REPORT_VALUECHANGED, XTP_ID_REPORT_CONTROL, OnReportValueChanged)
 ON_NOTIFY(NM_RCLICK, XTP_ID_REPORT_CONTROL, OnReportItemRClick)
 ON_NOTIFY(NM_CLICK, XTP_ID_REPORT_CONTROL, OnReportItemClick)
 ON_WM_LBUTTONUP()
END_MESSAGE_MAP()



Posted By: sserge
Date Posted: 12 February 2007 at 3:29pm
CXTPReportView is derived from CView.
 
You have to catch ON_WM_LBUTTONUP() in CXTPReportControl derived class.
 
CXTPReportControl is created as a child window in CXTPReportView and you  have no chances to click on CXTPReportView, because this report child window takes all view area

--
WBR,
Serge
 



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