Example: ListBox with Background Image

Lena smiles behind cells (columns are resizeable).

Sample project is here.

1 Like

Very Suspicious of random links like this.
Whats this about?
Need help?
Showing some technique?

If no reply, this may be SPAM or worse…

It’s an example showing how to give a desktop ListBox a seamless background image using CellBackgroundPaint.

Works fine on Xojo 2015r1 (with some regression).

But the image (thus lovely) is not appropriate: reading the text is close to impossible.

BTW: a jpg (in this case) loaded with Picture.OpenVector ?


A bit tall, but the Rainbow effect is a must. I created the artwork for someone who’s addres was 15 Rainbow Drive… :wink:

No tricks.

Function CellBackgroundPaint(g As Graphics, row As Integer, column As Integer) Handles CellBackgroundPaint as Boolean
  Var left,top,columnWidth,rowHeight as Integer
  Var i as Integer
  For i=0 to row-1
  For i=0 to column-1
  g.DrawPicture Self.p,0,0,columnWidth,rowHeight,left,top,columnWidth,rowHeight
End Function
1 Like