FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour also xbrowse with bitmaps
Posts: 3107
Joined: Fri Oct 07, 2005 06:28 PM
also xbrowse with bitmaps
Posted: Wed Feb 16, 2011 08:36 PM
I wish add bitmaps only for column number 1 and coloumn number 3
I try with

before create the xbrowse

oApp():oGrid := TXBrWin7():New( oApp():oDlg )
oApp():nTop := 00
oApp():nLeft := nSplit+2
oApp():nBottom := ::nGridBottom
oApp():nRight := ::nGridRight


then I list the fields I want on the table

aBrowse := { { { || HW->Laboratory }, i18n("Aula/lab"), 150 },;
{ { || HW->Inventario }, i18n("Inventario"), 90 },;
{ { || HW->type }, i18n("Tipo"), 90 },;
{ { || HW->Marca }, i18n("Marca"), 90 },;
{ { || HW->Modello }, i18n("Modello"), 90 },;
{ { || HW->Seriale }, i18n("Seriale"), 150 } }

FOR i := 1 TO Len(aBrowse)
oCol := oApp():AddCol()
oCol:bStrData := aBrowse[ i, 1 ]
oCol:cHeader := aBrowse[ i, 2 ]
oCol:nWidth := aBrowse[ i, 3 ]
NEXT

then I wish insert bitmaps ( for header and field) for column 1

WITH OBJECT oApp():aCols[1]
oCol:AddResource("sort3")
oCol:AddResource("sort4")
oCol:AddResource( 'TREE_AULE')
oCol:bBmpData := { || 3 }
oCol:nHeadBmpNo := 1
oCol:nHeadBmpAlign := AL_RIGHT
oCol:bStrData := { || HW->Laboratory}
oCol:cHeader := "Aula/lab"
END

then I wish insert bitmaps ( for header and field) for column 1

WITH OBJECT oApp():aCols[3]
oCol:AddResource("sort1")
oCol:AddResource("sort2")
oCol:AddResource( 'TREE_HARD')
oCol:AddResource( 'TREE_LAPTOP' )
oCol:AddResource( 'TREE_PRINTERS' )
oCol:AddResource( 'TREE_MONITOR' )
oCol:AddResource( 'TREE_KEYBOARD' )
oCol:AddResource( 'TREE_SWITCH' )
oCol:AddResource( 'TREE_MOUSE' )
oCol:AddResource( 'TREE_POCKET' )
oCol:AddResource( 'TREE_SCANNER' )
oCol:AddResource( 'TREE_PROJECT' )
oCol:AddResource( 'TREE_VCAM' )
oCol:AddResource( 'TREE_FCAM' )
oCol:AddResource( 'TREE_CAMERA' )
oCol:bBmpData := { || AScan( aItems, Trim( HW->type )) + 2 }
oCol:nHeadBmpNo := 2
oCol:nHeadBmpAlign := AL_RIGHT
END


but the procedure make a bad table :





there's not the bitmaps on first column and on the last column show bitmaps but they must be on third column instead on text

there is something of bad but I not Understand where is the error , can you help me please ?
Best Regards, Saludos



Falconi Silvio
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: also xbrowse with bitmaps
Posted: Thu Feb 17, 2011 05:00 AM

You wanted to add bitmaps to first and third columns.
But actually you added bitmaps to oCol, which is column no. 6.

Regards



G. N. Rao.

Hyderabad, India
Posts: 3107
Joined: Fri Oct 07, 2005 06:28 PM
Re: also xbrowse with bitmaps
Posted: Thu Feb 17, 2011 07:02 AM

opps you're right .. I have a tenth of a fever today !! and my head hurts!!

Best Regards, Saludos



Falconi Silvio

Continue the discussion