Results 1 to 5 of 5

Thread: adding subitems to a listview [resolved]

  1. #1

    Thread Starter
    Frenzied Member Ultimasnake's Avatar
    Join Date
    Feb 2002
    Location
    Amsterdam, holland
    Posts
    1,172

    adding subitems to a listview [resolved]

    I am rather stuck.. i try to add items and then fill the subitems..

    VB Code:
    1. fotolist.Items.Add(temprs.Fields("nr").Value)
    2.             fotolist.Items(fotolist.Items.Count - 1).SubItems(0).Text = temprs.Fields("datum").Value
    but this doesnt seem to work at all.... i changed the first column.. but when i set it to 1 it says the index is out of range , though there are 3 colums.........
    Last edited by Ultimasnake; Dec 3rd, 2003 at 09:26 AM.
    For my PC and MS Smartphone 2003 software visit
    http://www.ultimasoftware.nl

  2. #2
    Frenzied Member maged's Avatar
    Join Date
    Nov 2002
    Location
    Egypt
    Posts
    1,040
    well i am stuck too with this problem

    anyone please help us both

  3. #3
    Frenzied Member dynamic_sysop's Avatar
    Join Date
    Jun 2003
    Location
    Ashby, Leicestershire.
    Posts
    1,142
    assuming you are using Detail view ...
    VB Code:
    1. Dim lvi As New ListViewItem(" the listview item ")
    2.         Dim lvs As New ListViewItem.ListViewSubItem(lvi, " the sub item ")
    3.         lvi.SubItems.Add(lvs)
    4.         ListView1.Items.Add(lvi)
    ~
    if a post is resolved, please mark it as [Resolved]
    protected string get_Signature(){return Censored;}
    [vbcode][php] please use code tags when posting any code [/php][/vbcode]

  4. #4

    Thread Starter
    Frenzied Member Ultimasnake's Avatar
    Join Date
    Feb 2002
    Location
    Amsterdam, holland
    Posts
    1,172
    yet again a solution :d.. thanks
    For my PC and MS Smartphone 2003 software visit
    http://www.ultimasoftware.nl

  5. #5
    Frenzied Member maged's Avatar
    Join Date
    Nov 2002
    Location
    Egypt
    Posts
    1,040
    well another thanks from me here,

    But really it is now more complecated more than ever before.

    anyway , for sure it is not your fault

    thnkx again

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