Solved

how to make grid list control

Posted on 1998-10-07
7
247 Views
Last Modified: 2013-11-20
I want to have a grid List Control, how can I do it?
0
Comment
Question by:michali
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
7 Comments
 
LVL 8

Accepted Solution

by:
Answers2000 earned 50 total points
ID: 1323052
Goto
http://www.codeguru.com/listview/index.shtml

See these links (on this page)
Grid lines

Vertical lines for column borders - Zafir Anjum (1998/08/06)
Fix resizing problem in above article - Serge Wautier (1998/08/06)
Drawing horizontal and vertical gridlines - Zafir Anjum (1998/08/06)
List control with single / double separator lines - Zoran M.Todorovic (1998/10/05)


Basic idea is to make the control ownerdraw and paint each item yourself with additional grid lines

0
 

Author Comment

by:michali
ID: 1323053
I can't connect to this specific site, did you manage to connect this server?
0
 

Expert Comment

by:umarama
ID: 1323054
Hi michali.

If you are having VC 5.0 +, try this out.

OnInitDialog of the dlg which contains the listctrl, add the following lines :

DWORD dwStyle =
m_MyLstCtrl.SendMessage(LVM_GETEXTENDEDLISTVIEWSTYLE,0,0);
dwStyle |= LVS_EX_GRIDLINES;
m_MyLstCtrl.SendMessage(LVM_SETEXTENDEDLISTVIEWSTYLE, 0, dwStyle);

In addition to this style, if you are interested, you can try out the following:
dwStyle |= LVS_EX_FULLROWSELECT;
dwStyle |= LVS_EX_TRACKSELECT;
dwStyle |= LVS_EX_HEADERDRAGDROP;
dwStyle |= LVS_EX_SUBITEMIMAGES;

These are features included as member functions in 6.0 but are still available in 5.0 thru the above code.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:michali
ID: 1323055
thank you!
that is exactly what I needed.
0
 

Expert Comment

by:umarama
ID: 1323056
michali,

This is umarama.
Just confirming whether you liked my answer or Answers2000's since you have given him the points.
0
 

Author Comment

by:michali
ID: 1323057
I prefer the answer of umarama.
0
 

Expert Comment

by:umarama
ID: 1323058
michali Or Answers2000
 Do you know how to transfer the points to me ? I had this problem with a couple of other questions too ! I comment in a proposed answer and end up losing the points. PLease enlighten as I am new in this group.

Thanks.
0

Featured Post

Percona Live Europe 2017 | Sep 25 - 27, 2017

The Percona Live Open Source Database Conference Europe 2017 is the premier event for the diverse and active European open source database community, as well as businesses that develop and use open source database software.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses

631 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question