Click here to Skip to main content
15,904,346 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Easy question: Pin
georgiek507-Feb-03 7:38
georgiek507-Feb-03 7:38 
Generalbitmaps in statusbar Pin
Crash Operator6-Feb-03 13:20
Crash Operator6-Feb-03 13:20 
GeneralRe: bitmaps in statusbar Pin
-Dy6-Feb-03 23:04
-Dy6-Feb-03 23:04 
GeneralNot to Get Black background image Pin
mkashifkkj6-Feb-03 13:06
mkashifkkj6-Feb-03 13:06 
Generalavaoiding flicker on CUSTOMDRAW Pin
User 98856-Feb-03 12:39
User 98856-Feb-03 12:39 
GeneralRe: avaoiding flicker on CUSTOMDRAW Pin
Moak7-Feb-03 1:09
Moak7-Feb-03 1:09 
GeneralCHeaderCtrl Pin
User 98856-Feb-03 12:30
User 98856-Feb-03 12:30 
GeneralRe: CHeaderCtrl Pin
OBRon7-Feb-03 4:17
OBRon7-Feb-03 4:17 
I think you can trap for left mouse clicks on your list control and then do a hit test on the header control. Then you could launch your sort function within the mouse click rather than the looking for the OnColumnClick notification. Like the following:

CHeaderCtrl* header = m_ListCtrl.GetHeaderCtrl();
if (header)
{
CPoint headerPoint = point;
LV_HITTESTINFO hitTestInfo;

header->ScreenToClient(&headerPoint);

hitTestInfo.pt = headerPoint;
::SendMessage(header->m_hWnd, HDM_HITTEST, 0, (LONG)(HD_HITTESTINFO FAR*)(&hitTestInfo));

if (hitTestInfo.iItem >= 0) // User hit a header column
{
// Do sort routine here
}
}


Ron Ward
GeneralRe: CHeaderCtrl Pin
User 98857-Feb-03 4:31
User 98857-Feb-03 4:31 
GeneralCoding database ! Pin
Hadi Rezaee6-Feb-03 11:50
Hadi Rezaee6-Feb-03 11:50 
GeneralRe: Coding database ! Pin
Anonymous6-Feb-03 11:57
Anonymous6-Feb-03 11:57 
GeneralRe: Coding database ! Pin
Hadi Rezaee6-Feb-03 12:21
Hadi Rezaee6-Feb-03 12:21 
GeneralRe: Coding database ! Pin
Willem B7-Feb-03 2:18
Willem B7-Feb-03 2:18 
QuestionGet Network namnes and there IP ? Pin
Larsson6-Feb-03 11:36
Larsson6-Feb-03 11:36 
AnswerRe: Get Network namnes and there IP ? Pin
palbano6-Feb-03 15:20
palbano6-Feb-03 15:20 
GeneralRe: Get Network namnes and there IP ? Pin
Larsson12-Feb-03 5:48
Larsson12-Feb-03 5:48 
GeneralGDI+ and DirectX/direct video output Pin
Roman Nurik6-Feb-03 11:04
Roman Nurik6-Feb-03 11:04 
Question__ftol2 ?? where did it come from? .NET? Pin
Jared Allen6-Feb-03 10:24
Jared Allen6-Feb-03 10:24 
AnswerRe: __ftol2 ?? where did it come from? .NET? Pin
Joaquín M López Muñoz6-Feb-03 10:37
Joaquín M López Muñoz6-Feb-03 10:37 
GeneralRe: __ftol2 ?? where did it come from? .NET? Pin
Chris Losinger6-Feb-03 10:50
professionalChris Losinger6-Feb-03 10:50 
GeneralRe: __ftol2 ?? where did it come from? .NET? Pin
Jared Allen6-Feb-03 11:51
Jared Allen6-Feb-03 11:51 
GeneralRe: __ftol2 ?? where did it come from? .NET? Pin
Chris Losinger6-Feb-03 12:20
professionalChris Losinger6-Feb-03 12:20 
QuestioncreateThread , Prototype, and extren call correctness? Pin
Pecan2046-Feb-03 7:42
Pecan2046-Feb-03 7:42 
AnswerRe: createThread , Prototype, and extren call correctness? Pin
Joaquín M López Muñoz6-Feb-03 9:13
Joaquín M López Muñoz6-Feb-03 9:13 
GeneralRe: createThread , Prototype, and extren call correctness? Pin
Pecan2046-Feb-03 15:14
Pecan2046-Feb-03 15:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.