Click here to Skip to main content
15,851,711 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi codeproject friends,

right now im trying to get the state of an checkbox inside of a grid.
the checkbox will contorl the visibility of another dialog.
i will transfer it in a bool vector.
so how can i get the current state?
The Cell-funktions tutorial didnt gave me the right answer,
because i coudnt find any interactions, just display it there


thank you for helpin me
cheers!

What I have tried:

void CConfiguratorListSortByCtrl::OnEditVerify()
{
CUGCell cell;
GetCell(COLUMN_VISIBILITY,2, &cell);

if (cell.GetCellType() == UG_SUCCESS)
{cell.SetBackColor(m_FailureSalmonColor);}
else {cell.SetBackColor(m_HighlightedBackColor);}


SetCell(COLUMN_VISIBILITY,2, &cell);


}
//im using oneditverify to get a fast feedback about is it workin or not.
Posted
Updated 13-May-16 3:39am

C#
OnCellTypeNotify(long ID, int col,long row, long msg, LONG_PTR param);



msg == 53 if status changed
param == true if checked,
== false if unchecked.
 
Share this answer
 
for changing the (initial painted) state of an checkbox inside of a cell,
you have to change the property with
cell.SetNumber(1);-->checked, 0 = unchecked

unfortunately its not written down in the doku of the Ultimate Grid Control
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900