Bueno días, el ejemplo tuyo lo compile y anda.
A continuación comparto el código a lo mejor logran ver mi error
Code: Select all
*-----------------------------------------------------------
@ 0,0 XBROWSE ::oBrw OF hLays["H3"]:aVLayout[1]
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//1
oCol:bStrData := {|| ::oQry:id_articulo }
oCol:nDataStrAlign := AL_RIGHT
oCol:nWidth := 130
oCol:cHeader := "ID"
oCol:nHeadStrAlign := AL_CENTER
oCol:lHide := .T.
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//2
oCol:bStrData := {|| ::oQry:codigo_articulo }
oCol:nDataStrAlign := AL_LEFT
oCol:nWidth := 220
oCol:cHeader := "Código"
oCol:nHeadStrAlign := AL_LEFT
oCol:Cargo := "articulos.codigo_articulo"
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//3
oCol:bStrData := {|| ::oQry:nombreMarca }
oCol:nDataStrAlign := AL_LEFT
oCol:nWidth := 250
oCol:cHeader := "Marca"
oCol:nHeadStrAlign := AL_LEFT
oCol:Cargo := "articulos.id_marca"
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//4
oCol:bStrData := {|| ::oQry:descripcion }
oCol:nDataStrAlign := AL_LEFT
oCol:nWidth := 400
oCol:cHeader := "Descripción Artículo"
oCol:nHeadStrAlign := AL_LEFT
oCol:Cargo := "articulos.descripcion"
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//5
oCol:bStrData := {|| ::oQry:nombreRubro }
oCol:nDataStrAlign := AL_LEFT
oCol:nWidth := 251
oCol:cHeader := "Rubro"
oCol:nHeadStrAlign := AL_LEFT
oCol:Cargo := "articulos.id_rubro"
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//6
oCol:bStrData := {|| ::oQry:nombreLinea }
oCol:nDataStrAlign := AL_LEFT
oCol:nWidth := 252
oCol:cHeader := "Linea"
oCol:nHeadStrAlign := AL_LEFT
oCol:Cargo := "articulos.id_linea"
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//7
oCol:bStrData := {|| ::oQry:porcentaje_iva }
oCol:nDataStrAlign := AL_RIGHT
oCol:nWidth := 100
oCol:cHeader := "Iva"
oCol:nHeadStrAlign := AL_CENTER
oCol:lHide := .T.
*-----------------------------------------------------------
oCol := ::oBrw:AddCol()//8
oCol:bStrData := {|| ::oQry:precio_publico_sugerido }
oCol:nDataStrAlign := AL_RIGHT
oCol:nWidth := 150
oCol:cHeader := "Pre. Público"
oCol:nHeadStrAlign := AL_CENTER
*-----------------------------------------------------------
AEval( ::oBrw:aCols, {| o | o:oDataFont := oSistema:oFntBrw } )
AEval( ::oBrw:aCols, {| o | o:oHeaderFont := oSistema:oFntCab } )
//::oBrw:oRecSelFont := oFont // Valor predeterminado en oBrw: oFont
::oBrw:nRecSelHeadBmpNo := "Counter"
::oBrw:bRecSelData := { || ::oQry:nRecNo }
::oBrw:bRecSelHeader := { |brw| "Nr." }
::oBrw:bRecSelFooter := { |brw| brw:nLen }
::oBrw:nRecSelWidth := 60
::oBrw:nRecSelColor := 16762251
*-----------------------------------------------------------
::oBrw:nHeaderHeight := 40 // Altura cabeceras de columna
::oBrw:nMarqueeStyle := MARQSTYLE_HIGHLROW // Estilo marquesina (fila seleccionada) 0 No 1 Marquesina punteada celular 2 Solid celular 3 Resalte la celda 4 fila resaltada y Levante teléfono 5
::oBrw:nRowDividerStyle := LINESTYLE_LIGHTGRAY
::oBrw:nColDividerStyle := LINESTYLE_LIGHTGRAY
::oBrw:bClrSel := {||{nRGB(255,255,255),nRGB(000,128,255)}}// para barra de linea selecc cuando el control no tiene el foco
::oBrw:nStretchCol := STRETCHCOL_WIDEST
::oBrw:l2007 := (.F.)
::oBrw:lAllowColHiding := .F. // Anulo el menu contextual al hacer click sobre el Header del browse
::oBrw:nRowHeight := 40
::oBrw:bClrStd := { || { CLR_BLACK, If(::oBrw:KeyNo % 2 == 0, RGB(193,221,255), RGB(221,245,255) ) } } // colores para lineas normales
::oBrw:lHScroll := .T.
::oBrw:lVScroll := .T.
::oBrw:lColDividerComplete := .T. //completa pintado hasta el footer cuando lineas no llenan todo el browse
::oBrw:lFastEdit := .F.
::oBrw:lFooter := .T.
::oBrw:nFooterLines := 1 //Lineas del footer
::oBrw:nFooterHeight := 40 //Altura del Footer
::oBrw:bClrFooter := {|| { nRGB(255,255,255), 16762251 } }
::oBrw:SetColor( CLR_BLACK, RGB(193,221,255) )
*-----------------------------------------------------------
// BARRA DE BUSQUEDA
::oBrw:lGetBar := .T.
::oBrw:nGetBarHeight := 33
::oBrw:aCols[2]:uBarGetVal := Space(15)
::oBrw:aCols[2]:cBarGetBmp := "BB_SEARCH(30x30)"
::oBrw:aCols[2]:bBarGetAction := {|| ::SetFilterRegistro() }
::oBrw:aCols[2]:bBarGetValid := {|x| ::SetFilterRegistro(), .T.}
::oBrw:aCols[3]:uBarGetVal := Space(20)
::oBrw:aCols[3]:aBarGetList := ::aMarca
//::oBrw:aCols[3]:bBarGetChange := {|| ( ::validoMarca() ) }
//::oBrw:aCols[3]:bBarGetChange := {|| msginfo(::oBrw:aCols[ nPos ]) }
//::oBrw:aCols[4]:lBarGetOnKey := .T.
::oBrw:aCols[4]:uBarGetVal := Space(40)
::oBrw:aCols[4]:cBarGetBmp := "BB_SEARCH(30x30)"
::oBrw:aCols[4]:bBarGetAction := {|| ::SetFilterRegistro() } //::oBrw:aCols[4]:cBarGetPic := "@!" // MASCARA
::oBrw:aCols[4]:bBarGetValid := {|x| ::SetFilterRegistro(), .T.}
::oBrw:aCols[5]:uBarGetVal := Space(30)
::oBrw:aCols[5]:aBarGetList := ::aRubro
::oBrw:aCols[5]:bBarGetChange := {|| ::validoRubro() }
//::oBrw:aCols[5]:aBarGetList := { "one", "two", "three" }
::oBrw:aCols[6]:uBarGetVal := Space(25)
::oBrw:aCols[6]:aBarGetList := ::aLinea
//::oBrw:aCols[6]:bBarGetChange := {|| ::validoLinea() }
//::oBrw:aCols[6]:bBarGetChange := {|| msginfo(::oBrw:aCols[ ::oBrw:nColSel ]:nWidth) }
::oBrw:bClrEdits := { || { CLR_BLACK,rgb(255,250,240) } }
/*
oCol:aBarGetList: If you assign an array combobox will be displayed
oCol:bBarGetValid: You can take action when the user completes the entry
oCol:cBarGetBmp: bmp file name to show button on the get
oCol:bBarGetAction: Button action
oCol:bBarGetChange: as it means
*/
// BARRA DE BUSQUEDA
*-----------------------------------------------------------
::oBrw:SetDolphin( ::oQry,.F.,.T.)
::oBrw:CreateFromCode()
::oBrw:MakeTotals()
::oBrw:Refreshfooters()
::oBrw:Refresh()
hLays["H3"]:aVLayout[1]:oClient := ::oBrw
Saludos y gracias