Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » ArrayCtrl, HeaderCtrl & GridCtrl » mouse-event on arrayctrl-header
mouse-event on arrayctrl-header [message #13254] Wed, 26 December 2007 11:37 Go to next message
michael is currently offline  michael
Messages: 153
Registered: May 2007
Location: Germany
Experienced Member
I have an arrayctrl named datagrid. I catch mouse-events on this arrayctrl like this:

datagrid.WhenLeftClick = THISBACK(LCLICK_datagrid);

How can i catch mouse-events on the arraycrtl-column-title (The Header)?
Re: mouse-event on arrayctrl-header [message #13258 is a reply to message #13254] Wed, 26 December 2007 13:52 Go to previous message
michael is currently offline  michael
Messages: 153
Registered: May 2007
Location: Germany
Experienced Member
Found a solution:

datagrid.AddColumn("NAME").HeaderTab().WhenAction = THISBACK1(LCLICK_datagridHeader, 1);

But when i use this to sort an array how can i change the sort-order?
void MainWindow::LCLICK_datagridHeader(int column)
{
	datagrid.Sort(column);
}

[Updated on: Thu, 27 December 2007 22:57]

Report message to a moderator

Previous Topic: Bug in GridCtrl's WhenLeftDouble?
Next Topic: Selection changes before LostFocus() is called
Goto Forum:
  


Current Time: Sat Apr 27 09:49:59 CEST 2024

Total time taken to generate the page: 1.70379 seconds