Le 31 déc. 06 à 03:32 Matin, RBNUBE a écrit:

I'm trying to make some of my RB5.5.5 code compatible with RB2006r2.

In the CellBackgroundPaint event of a Listbox, the following is fine in RB
5.5.5, but causes an OutOfBounds exception in 2006r2.

  If me.CellTag(row,0) <> "CategoryRow" then
      // Do something here.
  End If

What is the proper way of dealing with this in RB2006r2 (or later)? I know that, for some reason, we have to check if there are rows in the Listbox,
but checking for ListCount first doesn't make a difference either.

The only thing that changed between RB 5.5 and 2005 is that you must compare ListCount with the "row" parameter. If you have done the following code, then I don't know the problem:

  If row<me.ListCount and me.CellTag(row,0) <> "CategoryRow" then
      // Do something here.
  End If_______________________________________________
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