Colegas, eso necesito, cambiar el color celeste que trae por defecto los BtnBmp en xbrowse y no encuentro la manera, adjunto imagen
Muchísimas gracias
Saludos
Error description: Error BASE/1004 No existe el m‚todo: SETCOLOR
Args:
[ 1] = U
[ 2] = N 0
[ 3] = N 16777215
Stack Calls
===========
Called from: => SETCOLOR( 0 )
Called from: C:\sipep_cliente\legajos.prg => TABLALEGAJOS( 85 )
METHOD ....
Local o := Self
o:oBtn....:SetColor
@ 100, 20 xBrowse oBrw2 DataSource oVar : aLeg Columns 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17 Pixel Of oVar : oWndChild2 NoBorder
With Object oBrw2
For i := 1 To Len( :aCols )
Switch i
Case 1
:aCols[ i ] : nWidth := 60
:aCols[ i ] : cHeader := 'Nº LEG.'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 2
:aCols[ i ] : nWidth := 260
:aCols[ i ] : cHeader := 'SECCIÓN'
:aCols[ i ] : nGrpHeight := 2
Exit
Case 3
:aCols[ i ] : cHeader := 'CARACTER'
:aCols[ i ] : nWidth := 100
:aCols[ i ] : nEditType := EDIT_LISTBOX
:aCols[ i ] : aEditListTxt := { "TITULAR", "SUPLENTE", "CONTRATADO", "PROVISIONAL" }
:aCols[ i ] : bOnPostEdit := { | o, x, n | UpdateCaracter( x ) }
:aCols[ i ] : cEditPicture := '@!'
Exit
Case 4
:aCols[ i ] : nWidth := 60
:aCols[ i ] : cHeader := 'ANTIG.'
:aCols[ i ] : nEditType := EDIT_BUTTON
:aCols[ i ] : bEditBlock := { | r, c, o | EditaAntiguedad( r, c, o ) }
:aCols[ i ] : bOnPostEdit := { | o, cVal | If ( cVal != nil, oVar : aLeg[ oBrw2 : nArrayAt ][ 4 ] := cVal, ) }
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 5
:aCols[ i ] : cHeader := 'CARGO'
:aCols[ i ] : nEditType := EDIT_BUTTON
:aCols[ i ] : bEditBlock := { | r, c, o | EditaCargo( r, c, o ) }
Exit
Case 6
:aCols[ i ] : cHeader := 'ESTADO'
:aCols[ i ] : nEditType := EDIT_LISTBOX
:aCols[ i ] : aEditListTxt := { "NORMAL", "LICENCIA", "BAJA" }
:aCols[ i ] : bOnPostEdit := { | o, x, n | UpdateEstado( x ) }
Exit
Case 7
:aCols[ i ] : cHeader := 'HORAS'
:aCols[ i ] : bEditBlock := { | r, c, o | EditaHoras( r, c, o ) }
:aCols[ i ] : nEditType := EDIT_BUTTON
:aCols[ i ] : nWidth := 50
:aCols[ i ] : AddBmpFile( "C:\FWH1204\bitmaps\AlphaBmp\bs_options.bmp" )
:aCols[ i ] : nAlphaLevel( 10 )
:aCols[ i ] : nBtnBmp := 1
:aCols[ i ] : lBtnTransparent := .t.
Exit
Case 8
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'DESCUENTO' + CRLF + 'PRESENTISMO'
:aCols[ i ] : nEditType := EDIT_LISTBOX
:aCols[ i ] : nDataStrAlign := 2
:aCols[ i ] : aEditListTxt := { "SI", "NO" }
:aCols[ i ] : bOnPostEdit := { | o, x, n | UpdateDescuentoPresentismo( x ) }
:aCols[ i ] : AddBmpFile( "c:\fwh1412\bitmaps\16x16\zoom2.bmp" )
:aCols[ i ] : nBtnBmp := 1
:aCols[ i ] : lBtnTransparent := .t.
Exit
Case 9
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'DESC. OBLIG.' + CRLF + 'DÍAS'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 10
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'ARTICULO DE' + CRLF + 'LICENCIA'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 11
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'FECHA INICIO' + CRLF + 'DE LICENCIA'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 12
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'FECHA FIN' + CRLF + 'DE LICENCIA'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 13
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'CON O SIN ' + CRLF + 'GOCE SUELDO'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 14
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'F. DE INGRESO'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 15
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'REEMPLAZA A'
Exit
Case 16
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'F. INICIO DE' + CRLF + 'LICENCIA'
:aCols[ i ] : nDataStrAlign := 2
Exit
Case 17
:aCols[ i ] : nWidth := 100
:aCols[ i ] : cHeader := 'F. FIN DE' + CRLF + 'LICENCIA'
:aCols[ i ] : nDataStrAlign := 2
Exit
EndSwitch
:aCols[ i ] : cHeader := Upper( :aCols[ i ] : cHeader )
:aCols[ i ] : oHeaderFont := oFont1
:aCols[ i ] : oDataFont := oFont2
:aCols[ i ] : nHeadStrAlign := 0
Next i
:bClrHeader := { || { 0, CLR_WHITE } }
:nRowHeight := 28
:nHeaderHeight := 40
:nColDividerStyle := 1
:nRowDividerStyle := 5
:nColAdvance := 50
:nColorPen := nRgb( 225, 225, 225 )
:nMarqueeStyle := 3
:nFreeze := 2
:nRecSelColor := CLR_WHITE
:bClrSelFocus := { || { CLR_WHITE, RGB( 43, 87, 154 ) } }
:nHeaderLines := 2
:bRClicked := { || MsgStop( oBrw2 :aCols[ 7 ] : oBtnList : ClassName() ) }
:lVScroll := .f.
:lFlatStyle := .t.
:l2007 := .f.
:lKinetic := .f.
:lAllowRowSizing := .f.
:lExcelCellWise := .t.
:lFreezeLikeExcel := .t.
:lFastEdit := .t.
:lColDividerComplete := .t.
:bKeyDown := { | nKey | KeyLegajos( nKey ) }
:SetGroupHeader( 'DATOS', 3, 14, oFont1 )
:SetGroupHeader( 'SOLO PARA SUPLENTES', 15, 17, oFont1 )
:CreateFromCode()
End
oVar : oWndChild2 : SetControl( oBrw2 )
// ::bClrHeader := {|| { GetSysColor( COLOR_BTNTEXT ), GetSysColor( COLOR_BTNFACE ) } }
::bClrHeader := {|| { GetSysColor( COLOR_BTNTEXT ), GetSysColor( COLOR_BTNFACE ), nRGB( 125, 165, 224 ), nRGB( 203, 225, 252 ) } }
::bClrFooter := ::bClrHeader
::bClrStd := {|| { CLR_BLACK, GetSysColor( COLOR_WINDOW )} }
::bClrSel := {|| { CLR_BLACK, GetSysColor( COLOR_INACTIVECAPTIONTEXT )} }
::bClrSelFocus := {|| { CLR_WHITE, GetSysColor( COLOR_HIGHLIGHT )} }
oBrw:aCols[ 1 ]:nEditType := EDIT_BUTTON
oBrw:aCols[ 1 ]:AddBmpFile( "..\bitmaps\AlphaBmp\sound.bmp" )
oBrw:aCols[ 1 ]:nHeadBmpNo := 1
METHOD CreateButtons() CLASS TXBrwColumn
.../...
@ 0,0 BTNBMP ::oBtnList RESOURCE "" OF ::oBrw NOBORDER SIZE 0,0
.../...
:SetColor( aColors[ 1 ], aColors[ 2 ] )
@ 0,0 BTNBMP ::oBtnList RESOURCE "" OF ::oBrw NoBorder SIZE 0,0 Transparent
::oBtnList:bAction := { || ::ShowBtnList() }
::oBtnList:hBitmap1 := FwDArrow()
::oBtnList:SetColor( 0, CLR_RED )
Return to FiveWin para Harbour/xHarbour
Users browsing this forum: No registered users and 24 guests