Results 1 to 4 of 4

Thread: ListView

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jan 2001
    Location
    United Kingdom
    Posts
    86
    Hi,
    I am using a listview to display data from a db, however i want to insert different fields into different column headings in the listview (using the report view), could any1 help me in showing me the code to add text to different columns?
    Kieran Smith
    'Computing' A Level Student

    [email protected]
    Visit my Home Page

    Visual C++ 6.0 Pro
    Visual Basic 6.0 Ent
    SQL, ADO, DAO


    "Computers in the future may weigh no more than 1.5 tons."
    -- Popular Mechanics, forecasting the relentless march of science, 1949

  2. #2
    Hyperactive Member DKCK's Avatar
    Join Date
    Dec 2000
    Location
    United States
    Posts
    329
    lstView.ColumnHeaders(Index).Text =

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jan 2001
    Location
    United Kingdom
    Posts
    86
    no, that would rename the title of the column report, i want to add an item wich says test in say 3 columns! i dont want to change the name of the column header.
    Kieran Smith
    'Computing' A Level Student

    [email protected]
    Visit my Home Page

    Visual C++ 6.0 Pro
    Visual Basic 6.0 Ent
    SQL, ADO, DAO


    "Computers in the future may weigh no more than 1.5 tons."
    -- Popular Mechanics, forecasting the relentless march of science, 1949

  4. #4
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    Code:
    Dim colData As ListItem
    
    Set colData = Listview1.ListItems.Add (,,"Title")
    
    colData.SubItems(1).Text = "hello"
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width