What are the steps to make the grid send notifications to its parent dialog?I have placed a grid in a dialog and would like the dialog to capture the grid's double-click event (and others as well).

Here are some steps:

1. Define your own message in a header:

// Custom Objective Grid Messages
#define OG_LBUTTONCLK         01

2. Override corresponding OG method:

protected:
virtual BOOL OnLButtonClickedRowCol(ROWCOL nRow, ROWCOL nCol, UINT
nFlags, CPoint pt);

3. In CPP send a message to the parent dialog:

// get a pointer to the parent dialog (works also if grid is embedded in a record info window)
CDialog* GetParentDialog(CWnd* pWnd)
{
   return (CDialog*) GXGetParentWnd(this, RUNTIME_CLASS(CDialog), TRUE);
}
BOOL CGXObGrid::OnLButtonClickedRowCol(ROWCOL nRow, ROWCOL nCol, UINT
nFlags, CPoint pt)
{
#ifndef _WIN32
   GetParentDialog(this)->SendMessage(WM_COMMAND, GetDlgCtrlID(), MAKELONG(m_hWnd, OG_LBUTTONCLK));
#else
GetParentDialog(this)->SendMessage(WM_COMMAND, MAKELONG(GetDlgCtrlID(),
OG_LBUTTONCLK), (LPARAM) m_hWnd );
#endif
   return TRUE;
}

4. In dialog message map, something like this:

ON_CONTROL(OG_LBUTTONDBLCLK, IDC_YOURGRID, OnOGLButtonDblClk)

5. Do whatever you need to do in function.