ListView Question

Posted on 2005-02-24
Medium Priority
Last Modified: 2010-05-02
If i have a ListView in Detail mode, how can i make make the Item Rows thicker without changing the font size? thanks
Question by:NewAgeNemesis
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

Expert Comment

ID: 13398300
What is Detail mode?  You mean View (Icon, SmallIcon, List, Report)?

Author Comment

ID: 13398902
ListView1.View = View.Details
LVL 53

Accepted Solution

Ryan Chong earned 500 total points
ID: 13399564
You can try bound that listivew control with an ImageList control, so that the items' height and width will be determine by the image size, like:

'You must add an image to the ImageList  before you execute the below scripts

Private Sub Form_Load()
    Set ListView1.SmallIcons = ImageList1
    ListView1.ColumnHeaders.Add , , "Column 1"
    ListView1.View = lvwReport
    For I = 1 To 20
        ListView1.ListItems.Add I, , "item " & I, , 1
    Next I
End Sub

Author Comment

ID: 13422013
i'm doing the listview with ListView1.View = View.Details so there will be no images

Author Comment

ID: 13424814
hey i played with that code and got it working actually, was just a little different since i'm using VB .NET following code did it for me, thanks:

 ListView1.View = View.Details
 ImageList1.ImageSize = New Size(30, 30)
 ListView1.SmallImageList = ImageList1

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month9 days, 17 hours left to enroll

762 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