Forum Discussion

Ethan's avatar
Ethan
New Member
2 years ago

MFC Grid | 2 tables in a Tab

Hi,

In a project I'm using 2 MFC grid tables in a TAB. So to know what column & row I selected I'm using this small function:

 

void CLoggingDlg::OnGridClickedCHMask(NMHDR *pNotifyStruct, LRESULT*)

{

      NM_GRIDVIEW* pItem = (NM_GRIDVIEW*)pNotifyStruct;

      m_rowSel = pItem->iRow;

      m_colSel = pItem->iColumn;

}

 

The issues is this always giving me the information about  the first table, even if I'm clicking on the 2 grid table m_colSel & m_rowSel is not getting updated.

 

So to get Row & col number from both the table what should I do, where I can define this function particularly for a grid.

Thanks
Subhash Chandra

No RepliesBe the first to reply