xbrowse SCROOL...

xbrowse SCROOL...

Postby goosfancito » Sun Nov 14, 2021 3:17 pm

Hola. Por favor podrian decirme porque esto no funciona? ya me he leido los post dicen que hay que poner un WINDOWS STYLE, pero yo trabajo con .res no con .rc
Code: Select all  Expand view  RUN

      :lKinetic            := .F.
      :ltransparent        := .F.
      :nHeaderHeight       := 29
      :nRowHeight          := 28
      :lHScroll            := (.T.)
      :lVScroll            := (.T.)
      :lRecordSelector     := .F.
      :lAllowColSwapping   := .F.
      :lColDividerComplete := .F.
      :nRowDividerStyle    := 4
      :nStretchCol         := STRETCHCOL_LAST
      :nColDividerStyle    := 4
      :L2007               := .T.
 


Es un problema que ya viene hace tiempo, no hay forma que se solucione definitivamente?
gracias.
FWH 21.02
Harbour 3.2.0dev (r2104281802)
Copyright (c) 1999-2021, https://harbour.github.io/
User avatar
goosfancito
 
Posts: 1954
Joined: Fri Oct 07, 2005 7:08 pm

Re: xbrowse SCROOL...

Postby karinha » Sun Nov 14, 2021 3:23 pm

Cual?

Code: Select all  Expand view  RUN

   :lHScroll            := (.T.)
   :lVScroll            := (.T.)
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7835
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xbrowse SCROOL...

Postby karinha » Sun Nov 14, 2021 3:33 pm

Teste \samples\COLIN.prg que está errado?

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7835
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xbrowse SCROOL...

Postby karinha » Sun Nov 14, 2021 3:50 pm

Mira:

Code: Select all  Expand view  RUN

// \samples\COLIN.PRG - Modificado en: 14/11/2021 - Joao.

#Include "FiveWin.ch"
#Include "xBrowse.ch"

#Define TRUE  .T.
#Define FALSE .F.

FUNCTION Main()

   LOCAL oWnd, oBrw, oCol

   REQUEST DBFCDX

   USE Colin NEW SHARED VIA "DBFCDX"

   DEFINE WINDOW oWnd TITLE "Class TXBrowse example"

   SET MESSAGE OF oWnd TO FWVERSION + ", " + FWCOPYRIGHT CENTERED TIME DATE

   @ 0, 0 XBROWSE oBrw OF oWnd ALIAS Alias()

   oBrw:nMarqueeStyle       := MARQSTYLE_HIGHLCELL
   oBrw:nColDividerStyle    := LINESTYLE_BLACK
   oBrw:nRowDividerStyle    := LINESTYLE_BLACK
   oBrw:lColDividerComplete := TRUE
   oBrw:lFastEdit := TRUE
   oBrw:nDatalines := 1
   oBrw:nRowHeight  := 24

   // AQUI:
   oBrw:lHScroll := TRUE // FALSE
   oBrw:lVScroll := TRUE // FALSE

   oBrw:lFooter := TRUE
   oBrw:bChange  := {|| oBrw:MakeTotals(), oBrw:Refresh() }
   // oBrw:nStretchCol := STRETCHCOL_LAST
   oBrw:bClrSel := {|| {  CLR_WHITE, CLR_BLUE } }
   oBrw:MakeTotals()

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Code"
   oCol:nWidth   :=  50
   oCol:cEditPicture := '@!'
   oCol:bEditValue := {|| Colin->CODE }
   oCol:nDataStyle := oCol:DefStyle( AL_LEFT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->CODE := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Description"
   oCol:nWidth   :=  220
   oCol:cEditPicture := '@'
   oCol:bEditValue := {|| Colin->DESC }
   oCol:nDataStyle := oCol:DefStyle( AL_LEFT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->DESC := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Qty"
   oCol:nWidth   :=  45
   oCol:cEditPicture := '9999'
   oCol:bEditValue := {|| Colin->qty }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->qty := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Cost"
   oCol:nWidth   :=  60

   // oCol:cEditPicture := '999999.99'
   oCol:cEditPicture := '€999999.99 '

   oCol:bEditValue := {|| Colin->cost }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->cost := v, ;
                                          Colin->charge := Colin->cost *      ;
                                          Colin->qty, dbCommit(), dbUnlock(), ;
                           oBrw:MakeTotals(), oBrw:Refresh(), oBrw:SetFocus() }
   oCol:lTotal := TRUE
   oCol:nTotal := 0

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Charget"
   oCol:nWidth   :=  60
   oCol:cEditPicture := '999999.99'
   oCol:bEditValue := {|| Colin->charge }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->charge := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol:lTotal := TRUE
   oCol:nTotal := 0

   oBrw:CreateFromCode()

   oWnd:oClient := oBrw

   ACTIVATE WINDOW oWnd MAXIMIZED ;
      ON INIT( oBrw:MakeTotals(), CLRTEST( CLR_WHITE, CLR_WHITE ) )

RETURN NIL

// COLORES EN WINDOW -FUNCIONA--      +-

#pragma BEGINDUMP

#include <hbapi.h>
#include <windows.h>

HB_FUNC( CLRTEST )
{
   int aElements[2] = { COLOR_CAPTIONTEXT, COLOR_ACTIVECAPTION };
   DWORD aColors[2];

   aColors[ 0 ] = hb_parnl( 1 );
   aColors[ 1 ] = hb_parnl( 2 );
   SetSysColors( 2, aElements, aColors );

}

#pragma ENDDUMP

// ???
/*
DLL32 Function SetSysColors ( nChanges As LONG, lpSysColor As LONG, lpColorValues As LONG) As LONG ;
 PASCAL FROM "SetSysColors" Lib "user32"
*/

 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7835
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xbrowse SCROOL...

Postby goosfancito » Sun Nov 14, 2021 4:15 pm

karinha wrote:Mira:

Code: Select all  Expand view  RUN

// \samples\COLIN.PRG - Modificado en: 14/11/2021 - Joao.

#Include "FiveWin.ch"
#Include "xBrowse.ch"

#Define TRUE  .T.
#Define FALSE .F.

FUNCTION Main()

   LOCAL oWnd, oBrw, oCol

   REQUEST DBFCDX

   USE Colin NEW SHARED VIA "DBFCDX"

   DEFINE WINDOW oWnd TITLE "Class TXBrowse example"

   SET MESSAGE OF oWnd TO FWVERSION + ", " + FWCOPYRIGHT CENTERED TIME DATE

   @ 0, 0 XBROWSE oBrw OF oWnd ALIAS Alias()

   oBrw:nMarqueeStyle       := MARQSTYLE_HIGHLCELL
   oBrw:nColDividerStyle    := LINESTYLE_BLACK
   oBrw:nRowDividerStyle    := LINESTYLE_BLACK
   oBrw:lColDividerComplete := TRUE
   oBrw:lFastEdit := TRUE
   oBrw:nDatalines := 1
   oBrw:nRowHeight  := 24

   // AQUI:
   oBrw:lHScroll := TRUE // FALSE
   oBrw:lVScroll := TRUE // FALSE

   oBrw:lFooter := TRUE
   oBrw:bChange  := {|| oBrw:MakeTotals(), oBrw:Refresh() }
   // oBrw:nStretchCol := STRETCHCOL_LAST
   oBrw:bClrSel := {|| {  CLR_WHITE, CLR_BLUE } }
   oBrw:MakeTotals()

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Code"
   oCol:nWidth   :=  50
   oCol:cEditPicture := '@!'
   oCol:bEditValue := {|| Colin->CODE }
   oCol:nDataStyle := oCol:DefStyle( AL_LEFT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->CODE := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Description"
   oCol:nWidth   :=  220
   oCol:cEditPicture := '@'
   oCol:bEditValue := {|| Colin->DESC }
   oCol:nDataStyle := oCol:DefStyle( AL_LEFT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->DESC := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Qty"
   oCol:nWidth   :=  45
   oCol:cEditPicture := '9999'
   oCol:bEditValue := {|| Colin->qty }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->qty := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Cost"
   oCol:nWidth   :=  60

   // oCol:cEditPicture := '999999.99'
   oCol:cEditPicture := '€999999.99 '

   oCol:bEditValue := {|| Colin->cost }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->cost := v, ;
                                          Colin->charge := Colin->cost *      ;
                                          Colin->qty, dbCommit(), dbUnlock(), ;
                           oBrw:MakeTotals(), oBrw:Refresh(), oBrw:SetFocus() }
   oCol:lTotal := TRUE
   oCol:nTotal := 0

   oCol := oBrw:AddCol()
   oCol:cHeader  := "Charget"
   oCol:nWidth   :=  60
   oCol:cEditPicture := '999999.99'
   oCol:bEditValue := {|| Colin->charge }
   oCol:nDataStyle := oCol:DefStyle( AL_RIGHT, .T. )
   oCol:nEditType  := EDIT_GET
   oCol:bOnPostEdit := {| o, v | RLock(), Colin->charge := v, dbCommit(), ;
                          dbUnlock(), oBrw:Refresh(), oBrw:SetFocus() }

   oCol:lTotal := TRUE
   oCol:nTotal := 0

   oBrw:CreateFromCode()

   oWnd:oClient := oBrw

   ACTIVATE WINDOW oWnd MAXIMIZED ;
      ON INIT( oBrw:MakeTotals(), CLRTEST( CLR_WHITE, CLR_WHITE ) )

RETURN NIL

// COLORES EN WINDOW -FUNCIONA--      +-

#pragma BEGINDUMP

#include <hbapi.h>
#include <windows.h>

HB_FUNC( CLRTEST )
{
   int aElements[2] = { COLOR_CAPTIONTEXT, COLOR_ACTIVECAPTION };
   DWORD aColors[2];

   aColors[ 0 ] = hb_parnl( 1 );
   aColors[ 1 ] = hb_parnl( 2 );
   SetSysColors( 2, aElements, aColors );

}

#pragma ENDDUMP

// ???
/*
DLL32 Function SetSysColors ( nChanges As LONG, lpSysColor As LONG, lpColorValues As LONG) As LONG ;
 PASCAL FROM "SetSysColors" Lib "user32"
*/

 


Regards, saludos.



Hola. todo eso ya he probado. y nada resulto. utilizo el control LISTBOX en pelesC ya he probado con combobox y nada.
FWH 21.02
Harbour 3.2.0dev (r2104281802)
Copyright (c) 1999-2021, https://harbour.github.io/
User avatar
goosfancito
 
Posts: 1954
Joined: Fri Oct 07, 2005 7:08 pm

Re: xbrowse SCROOL...

Postby karinha » Sun Nov 14, 2021 7:27 pm

Post un ejemplo de como usted está haciendo para testes. Donde está el error que usted produce. Mister Nages puede mirar. Saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7835
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xbrowse SCROOL...

Postby JoseAlvarez » Sun Nov 14, 2021 10:02 pm

Hola,

Si usas PELLES revisa la propiedad DISABLE NO SCROLL debe estar en YES

Espero sea eso.
"Los errores en programación, siempre están entre la silla y el teclado..."

Fwh 19.06 32 bits + Harbour 3.2 + Borland 7.4 + MariaDB + TDolphin

Carora, Estado Lara, Venezuela.
User avatar
JoseAlvarez
 
Posts: 798
Joined: Sun Nov 09, 2014 5:01 pm

Re: xbrowse SCROOL...

Postby goosfancito » Mon Nov 15, 2021 9:12 am

JoseAlvarez wrote:Hola,

Si usas PELLES revisa la propiedad DISABLE NO SCROLL debe estar en YES

Espero sea eso.


FUNCIONO!
perfecto! gracias
FWH 21.02
Harbour 3.2.0dev (r2104281802)
Copyright (c) 1999-2021, https://harbour.github.io/
User avatar
goosfancito
 
Posts: 1954
Joined: Fri Oct 07, 2005 7:08 pm


Return to FiveWin para Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 54 guests