Data Access Worldwide Knowledge Base
Article ID 2302 Article Title HOWTO: Make a treeview item bold Article URL http://www.dataaccess.com/kbasepublic/KBPrint.asp?ArticleID=2302 KBase Category VDF12 Date Created 04/05/2007 Last Edit Date 04/05/2007
Article Text
QUESTION:
I see that VDF12 Studio has the ability to show one of its items in a bold text. How can I do the same in my VDF12 program.
ANSWER:
The Visual DataFlex Treeview class does not have a method to set this state. With the enclosed class you can set a particular item bold (for example the current item) by adding the following code to your treeview object.
Procedure OnItemChanged Handle hItem Handle hItemOld
Set BoldState hItemOld To False
Set BoldState hItem To True
Forward Send OnItemChanged hItem hItemOld
End_Procedure
So the steps are:
- Change the class of your treeview object from TreeView to cBoldTreeView
- Add code (like above) to really change the bold state
Of course you can merge this code with your own subclass of the DataFlex Treeview class
Web Links Related to this Article
File cBoldTreeView.Pkg
URL=http://www.dataaccess.com/KBasePublic/Files/2302.cBoldTreeView.Pkg
Email this Article
Email this Article to a Colleague
Send Feedback on this Article to Data Access Worldwide
Copyright ©2010 Data Access Corporation. All rights reserved.
The information provided in the Data Access Technical Knowledge Base is provided "as is" without warranty of any kind. Data Access Corporation disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. In no event shall Data Access Corporation or its suppliers be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages, even if Data Access Corporation or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for consequential or incidental damages so the foregoing limitation may not apply.