   Set List View Header Sort Arrow C++ Win32
  I use the below code and it returns true...But no arrow appears. [Express Edition 2010, default setting for new win32 project]Anyone have an idea what I'm doing wrong?typedef enum {   SHOW_NO_ARROW,   SHOW_UP_ARROW,   SHOW_DOWN_ARROW} SHOW_ARROW;BOOL ListView_SetHeaderSortImage(HWND listView, int  columnIndex, SHOW_ARROW showArrow) {  HWND    hHeader  = NULL;HDITEM  hdrItem  = { 0 };hHeader = ListView_GetHeader(listView);if (hHeader){hdrItem.mask = HDI_FORMAT;if ( Header_GetItem(hHeader, columnIndex, &hdrItem) ){if (showArrow == SHOW_UP_ARROW){hdrItem.fmt = (hdrItem.fmt & ~HDF_SORTDOWN) | HDF_SORTUP;}else if (showArrow == SHOW_DOWN_ARROW){hdrItem.fmt = (hdrItem.fmt & ~HDF_SORTUP) | HDF_SORTDOWN;}else {hdrItem.fmt = hdrItem.fmt & ~(HDF_SORTDOWN | HDF_SORTUP);}return Header_SetItem(hHeader, columnIndex, &hdrItem);}}return FALSE;};//call codeHWND LV = GetDlgItem(hWnd, ID_LISTVIEW);BOOL ret = ListView_SetHeaderSortImage(LV, 1, SHOW_UP_ARROW);// creation codelist = CreateWindowEx(WS_EX_CLIENTEDGE, WC_LISTVIEW, L"", WS_VISIBLE | WS_CHILD | LVS_REPORT | LVS_SHOWSELALWAYS | LVS_SINGLESEL, 0, 0, rect.right - rect.left, rect.bottom - rect.top, hWnd,(HMENU)ID_LISTVIEW, cs->hInstance, NULL);ListView_SetExtendedListViewStyle(list, LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES | LVS_EX_HEADERDRAGDROP | LVS_EX_DOUBLEBUFFER | LVS_EX_TRANSPARENTBKGND);/source]
  I've recently(ish) upgraded a project that used a sort triangle in the Listview header row, and before I can help, I need to know:Which operating system is this happening on, andWhat version of Common Controls are you binding to? CommCtrl v4.7 or v6?   ;Quote:Original post by iMalcI've recently(ish) upgraded a project that used a sort triangle in the Listview header row, and before I can help, I need to know:Which operating system is this happening onWin 7.Quote:Original post by iMalcWhat version of Common Controls are you binding to? CommCtrl v4.7 or v6?Whatever the default is for Visual C++ express edition 2010...Which if I'm not mistaken is the most current version.;  I checked it out and it turns out it wasn't linking to newest version. Code fix.#pragma comment(linker,"\"/manifestdependency:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"")