> Thanks for all your help but now the program give me an Out-Of-Bounds
> exception error.  So I had to give up on it.  Not sure why.

Using the debugger to look at where the exception occurs would
probably help a lot. If you don't learn how to use the debugger at a
basic level you're probably not going to get very far with RB (or any
other language).

Your problem might be that CellBackgroundPaint is called for "empty"
rows in the listbox; i.e. the ones that are visible but that you
haven't added using AddRow. (This is so that people can paint
background stripes for the full height of the listbox even if there
are just a few rows of data. Most Listbox events don't behave this
way; many consider this a design flaw in RB.)

Try wrapping your CellBackgroundPaint code in this:

if row < me.ListCount then // don't mess with empty rows
  // your code goes here
end if

lj
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to