PropertyGridItemEnum Selection... |
Post Reply |
Author | |
cooltoki
Newbie Joined: 18 October 2012 Status: Offline Points: 5 |
Post Options
Thanks(0)
Posted: 18 October 2012 at 4:40am |
Hello.
How can I unselect on CXTPPropertyGridItemEnum ?
for example.
CXTPPropertyGrid m_wndGrid;
CXTPPropertyGridItem* pBase = m_wndGrid.AddCategory( ID_PROP_BASE );
CXTPPropertyGridItem* pItem;
pItem = pBase->AddChildItem( new CXTPPropertyGridItemEnum("Test") );
pItem->GetConstraints()->AddConstraint( L"Test 01", 0 ); pItem->GetConstraints()->AddConstraint( L"Test 02", 1 ); ............
In above code, "Test" grid item is selected "Test 01" (by default value 0(zero)).
But, in some cases, I want to NOT SELECT "Test" grid item.
pItem->GetConstraints()->SetCurrent( -1 );
It does not work.
previous selection is still.
How should I do ????
|
|
cooltoki
Newbie Joined: 18 October 2012 Status: Offline Points: 5 |
Post Options
Thanks(0)
|
Ah... CXTPPropertyGridItemEnum unselection is successed.
CXTPPropertyGridItemEnum.SetEnum( -1 ); But, I want to same things as Enum to CXTPPropertyGridItemNumber. I override CXTPPropertyGridItemNumber and use SetEditText( L"" ). It works when that item is selected. but still displayed with "0" values if not selected. How should i do ???
|
|
cooltoki
Newbie Joined: 18 October 2012 Status: Offline Points: 5 |
Post Options
Thanks(0)
|
Ah... It is solved by calling SetValue( L"" ) of CXTPPropertyGridItem class.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |