Re: vb6 multicol combo




"arpi shah" <arpishah123@xxxxxxxxx> wrote in message
news:emf$52ErHHA.4300@xxxxxxxxxxxxxxxxxxxxxxx
Hi,

I have trying to load data into combobox by using

temp = rs!id
combo.additem rs!name,temp

i am not sure why does it gives me error that invalid procedure or call?



What is the data type of your temp variable? What is the *actual* value
assigned to your temp variable?

The 2nd parameter of the ComboBox's AddItem method is an index specifying
where in the list you want the item added. It must be numeric (generally
Integer or Long). Also, it must be a valid value. For example, if you have
1 item added already and try this code:

combo.AddItem rs!name, 2

you'll get this error because 2 is not a valid value for an index (you'd
need at least one more item before 2 is valid).

--
Mike
Microsoft Visual Basic MVP


.



Relevant Pages

  • mysql sql statement running in ANT
    ... I have a script in ANT to load data from a data file and then update a tmp ... the temp table. ...
    (comp.lang.java.databases)
  • vb6 multicol combo
    ... I have trying to load data into combobox by using ... temp = rs!id ... i am not sure why does it gives me error that invalid procedure or call? ...
    (microsoft.public.vb.general.discussion)
  • Re: vb6 multicol combo
    ... I have trying to load data into combobox by using ... i am not sure why does it gives me error that invalid procedure or call? ... The combobox that ships with VB has no support, at all, for multiple ... .ItemData= temp ...
    (microsoft.public.vb.general.discussion)