I am using a list view and when the listview is created I am giving it 2 extended style properties:
I want to add function in the MainFrame's Menu to turn off and on the Gridlines style: this is what i am using:
if(m_pListView->GetExtendedStyle()==LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES)
if(m_pListView->GetExtendedStyle() == LVS_EX_FULLROWSELECT )
m_pListView->SetExtendedStyle( LVS_EX_FULLROWSELECT |LVS_EX_GRIDLINES );
What this does is when the Listview is first created, it has fullrowselect and gridlines styles, but when selecting OnViewGridlines() function from the menu, the grids will turn off, and then re-appear immediately. how can I set this function to turn off the gridlines (but keep the fullrowselect style) when selecting that menu option, and turn back on the next time selecting that menu option?( Just like the show/hide toolbars function, under the View-Toolbars menu).