Print Page | Close Window

BS_3STATE vs. BS_CHECKBOX in CXTCheckListBox

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Controls
Forum Description: Topics Related to Codejock Controls
URL: http://forum.codejock.com/forum_posts.asp?TID=17671
Printed Date: 17 May 2024 at 11:32pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: BS_3STATE vs. BS_CHECKBOX in CXTCheckListBox
Posted By: cpede
Subject: BS_3STATE vs. BS_CHECKBOX in CXTCheckListBox
Date Posted: 14 December 2010 at 5:19am
You write the following in the doc for the CXTCheckListBox control:
 
// Remarks:
// Styles to be added or removed can be combined by using the bitwise
// OR (|) operator. It can be one or more of the following:
// * <b>BS_3STATE</b> Same as a check box, exce..............
 
Actually it cannot be one or more, since your code does this check:
 
ASSERT(
  nStyle == 0 ||
  nStyle == BS_CHECKBOX ||
  nStyle == BS_AUTOCHECKBOX ||
  nStyle == BS_AUTO3STATE ||
  nStyle == BS_3STATE);
I wanted to be able programmably to set an item to 3STATE, while the user should only be able to select and deselected items. Can this be done ?
 
-cpede


-------------
Product: Xtreme ToolkitPro (22.1.0)
Platform: Windows 10 (x64)
Language: Visual Studio 2017 (C++)



Replies:
Posted By: Oleg
Date Posted: 15 December 2010 at 1:37am
Hi,

Thanks, description fixed.


You can set style to BS_AUTO3STATE  and in CLBN_CHKCHANGE handler change manuall check state to "0" if its "2".


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net