List control with single / double separator lines Oklahoma

Placing row and column seperators in a listview

Local Companies

Amercian Education Corporation
405-840-6031
7506 Broadway Ext
Oklahoma City, OK
Midwest CAM Solutions (GibbsCAM)
763-560-6567
NOW SERVING: OKLAHOMA
Oklahoma City, OK
Dreyer Software Inc
918-838-7638
PO Box 3391
Tulsa, OK
Tah Software Systems
405-478-3962
3400 NE 115th St
Oklahoma City, OK
B Solutions LLC
918-749-9200
5645 S Madison Ave
Tulsa, OK
Anyware Mobile Solutions
918-280-8693
5800 E Skelly DR
Tulsa, OK
Earnest Computer Service
405-732-1233
7005 SE 15th St
Oklahoma City, OK
Axis Integrated Solutions
918-488-1881
2818 E 81st Pl
Tulsa, OK
Software Etc
918-254-9124
Woodland Hills Mall
Tulsa, OK
Griffey & Associates
918-627-6399
5350 E 46th Street Suite 145
Tulsa, OK

provided by: 
Originally published at Internet.com


This article describes how to add separator lines (single line or double line) to a list control derived from CListCtrl. This technique requires that the list control is owner drawn. This article also demonstrates how to prevent row selection in a list control.

grid_separator.gif (2590 bytes)

How to do it?



Let's assume that we have a class TVisualListCtrl derived from CListCtrl. Objects of this class correspond to list control resources (each list control must be ownerdrawn). In order to implement support for separator lines, we have to add several features to this class.

Step 1.

Add a public enum type containing the separator line identifiers and 2 public functions for inserting a separator line and checking whether the item is separator or not. class TVisualCtrlList : public CListCtrl { public: enum ESeparator { SEPARATOR_SINGLE, SEPARATOR_DOUBLE }; ..... public: .... BOOL IsSeparator(int row); int InsertSeparator(int row, ESeparator separator = SEPARATOR_SINGLE); };

Also create 2 constant strings (within a class or as local variables in a .cpp implementation file) which are inserted into the list control. These strings have a special meaning to the class implementation since they are actually aliases to separator lines. const CString SingleSeparator = _T("--"); const CString DoubleSeparator = _T("==="); ...

Read article at Internet.com site

Featured Local Company

Anyware Mobile Solutions

918-280-8693
5800 E Skelly DR
Tulsa, OK

Regional Articles
- List control with single / double separator lines Ada OK
- List control with single / double separator lines Altus OK
- List control with single / double separator lines Ardmore OK
- List control with single / double separator lines Bartlesville OK
- List control with single / double separator lines Bethany OK
- List control with single / double separator lines Bixby OK
- List control with single / double separator lines Broken Arrow OK
- List control with single / double separator lines Chickasha OK
- List control with single / double separator lines Choctaw OK
- List control with single / double separator lines Claremore OK
- List control with single / double separator lines Duncan OK
- List control with single / double separator lines Durant OK
- List control with single / double separator lines Edmond OK
- List control with single / double separator lines El Reno OK
- List control with single / double separator lines Enid OK
- List control with single / double separator lines Guthrie OK
- List control with single / double separator lines Lawton OK
- List control with single / double separator lines Mcalester OK
- List control with single / double separator lines Muskogee OK
- List control with single / double separator lines Mustang OK
- List control with single / double separator lines Norman OK
- List control with single / double separator lines Oklahoma City OK
- List control with single / double separator lines Okmulgee OK
- List control with single / double separator lines Owasso OK
- List control with single / double separator lines Ponca City OK
- List control with single / double separator lines Pryor OK
- List control with single / double separator lines Sand Springs OK
- List control with single / double separator lines Sapulpa OK
- List control with single / double separator lines Shawnee OK
- List control with single / double separator lines Stillwater OK
- List control with single / double separator lines Tahlequah OK
- List control with single / double separator lines Tulsa OK
- List control with single / double separator lines Woodward OK
- List control with single / double separator lines Yukon OK

Topics: 
Architecture & Design Languages & Tools Project Management Web Services
Database Microsoft & .NET Security Wireless
Java Open Source Techniques XML