Adblock breaks this site

Need help adding info from listboxes into combo boxes

Discussion in 'Programming General' started by fury6000, Apr 26, 2009.

  1. fury6000

    fury6000 Member

    Joined:
    Jan 21, 2008
    Posts:
    34
    Referrals:
    0
    Sythe Gold:
    0
    Need help adding info from listboxes into combo boxes

    Ok so im working on a program where the user enters something into a textbox and it appears in a listbox. good that works, but now the next part is that the user hits the continue button, and on the next form there is a combo box and i want the info from the listboxes from the previous form in the combo box. I made it into an array but its not workin. help would be appreciated :cool:
     
  2. jdsfighter

    jdsfighter Forum Addict
    Visual Basic Programmers

    Joined:
    Jan 21, 2007
    Posts:
    603
    Referrals:
    0
    Sythe Gold:
    0
    Need help adding info from listboxes into combo boxes

    Is this sufficient?

    Code:
    Private Sub Command1_Click()
    Form2.Show
    For i=0 to List1.Listcount-1
    Form2.Combo1.Additem list1.list(i)
    next
    end sub
     
  3. MasonSoiza

    MasonSoiza Newcomer

    Joined:
    May 5, 2009
    Posts:
    0
    Referrals:
    0
    Sythe Gold:
    0
    Need help adding info from listboxes into combo boxes

    this is better:

    sub AddToCombo
    dim i as integer
    i = 0 to list1.listcount
    combo1.additem list1.list(i)
    next i
    End sub
     
< [Tutorial] Multi-Threading | [VB.Net] How Can I Mute My App? >


 
 
Adblock breaks this site