How can i use the array < bBmpData > in xBrowse ?

How can i use the array < bBmpData > in xBrowse ?

Postby ukoenig » Tue Apr 01, 2008 12:27 am

Hello,

For xBrowse-testing, i fill the array < bBmpData > with bitmaps.
To see the normal column without bitmap, i set bBmpData := NIL.
It works and i don't see a bitmap in the Col.
When i choose another bitmap for a test, the array is not empty.
the new bitmap is shown after the old ones from before.

Image

Code: Select all  Expand view  RUN

for n = 1 to Len( oLbx1:aCols )
   oLbx1:aCols[ n ]:cHeader = Padr("Font 1", 10)
   oLbx1:aCols[ n ]:oDataFont = xBFont1
   oLbx1:aCols[ n ]:bClrStd := ;
         {|| { BR_TCOLOR, ;
               IF ( EVAL ( oLbx1:bKeyno, NIL, oLbx1 ) %2 == 0, ;
                    BR_COLOR1, BR_COLOR2 ) } }
   IF !empty(e_BRBMP)                             // The selected Bitmap
       cBMP := ALLTRIM(e_BRBMP) + ".BMP"
       oLbx1:aCols[ 1 ]:AddBmpFile(cBMP)
       oLbx1:aCols[ 1 ]:bBmpData := {|| oLbx1:nArrayAt }
   ELSE
       oLbx1:aCols[ 1 ]:bBmpData := NIL   // clears the col from BMP   
   ENDIF
next



How can i clear the Array, so that the next bitmap-test
starts at top of the browser ?

Regards

Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Postby demont frank » Tue Apr 01, 2008 5:56 am

In txbrwColumn :

DATA aBitmaps // Two dimension arrays that holds all the bitmaps added
// aBitmaps[n, 1] -> handle
// aBitmaps[n, 2] -> palette
// aBitmaps[n, 3] -> width
// aBitmaps[n, 4] -> heigth

I suppose that you can :

oCol:aBitmaps := {}

Frank
demont frank
 
Posts: 167
Joined: Thu Mar 22, 2007 11:24 am

Destroy all bitmaps of a Col

Postby ukoenig » Wed Apr 02, 2008 7:11 pm

Hello

The Problem is solved

I used

ASIZE( oLbx1:aCols[1]:aBitmaps,0)

to clear the bitmap-array of Col 1

Regards

Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot], nageswaragunupudi, Otto and 37 guests