problemas con xBrowse: NO FUNCIONA oBrw:VGoBottom() [solucio

problemas con xBrowse: NO FUNCIONA oBrw:VGoBottom() [solucio

Postby MOISES » Tue Jun 09, 2020 8:36 am

Buenos días Antonio,

Para acabar de solucionar el problema de xBrowse y SQLRDD, dado que Nages no contesta a los mensajes, necesito poder mover la barra de scroll vertical.

Sin embargo, oBrw:VGoBottom() ni SendMsg( VK_DOWN ) funcionan. No hacen nada.

Aquí va un ejemplo.

Code: Select all  Expand view
#Include "FiveWin.Ch"
#include "xbrowse.ch"

#include "hbcompat.ch"



FUNCTION Main()

   use c:\fwh\samples\customer

   TESTBROWSE()

   dbcloseall()


   quit


return nil





function TESTBROWSE()

   local oDlg
   local oBrw

   define dialog oDlg title "Test xBrowse " + cvaltochar(datetime()) from 0,0 to 24,79


    @ 0,0 xbrowse oBrw datasource alias() of oDlg fastedit autocols autosort ;
    SIZE -1, -1 PIXEL

    oBrw:nRowHeight := 25


    oBrw:lAutoappend := .t.
    oBrw:CreateFromCode()


    activate dialog oDlg centered ;
             on init ( oBrw:VGoBottom(), oBrw:oVScroll:SendMsg( VK_DOWN ) )

return nil
 


Te agradecería por favor tu ayuda, dado que llevo con este problema desde diciembre y los clientes están sumamente cabreados.

Muchas gracias. Un saludo
Last edited by MOISES on Thu Jun 11, 2020 12:14 pm, edited 1 time in total.
Saludos / Regards,

FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
MOISES
 
Posts: 838
Joined: Wed Aug 22, 2007 10:09 am

Re: problemas con xBrowse: NO FUNCIONA oBrw:VGoBottom()

Postby acuellar » Tue Jun 09, 2020 11:30 am

Estimado Moises

Si la idea es enviar al último registro yo uso GoBottom() y nunca he visto VGoBottom()
Saludos,

Adhemar C.
User avatar
acuellar
 
Posts: 1594
Joined: Tue Oct 28, 2008 6:26 pm
Location: Santa Cruz-Bolivia

Re: problemas con xBrowse: NO FUNCIONA oBrw:VGoBottom()

Postby MOISES » Tue Jun 09, 2020 12:57 pm

Muchas gracias por tu respuesta.

El problema es que con SQLRRD, al hacer dbgobottom() no baja la barra de scroll, ni tampoco funciona el método para forzarlo, ni sendmsg.
Saludos / Regards,

FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
MOISES
 
Posts: 838
Joined: Wed Aug 22, 2007 10:09 am

Re: problemas con xBrowse: NO FUNCIONA oBrw:VGoBottom()

Postby MOISES » Thu Jun 11, 2020 12:12 pm

Gracias a la ayuda de Cristóbal, este es el fix:

Code: Select all  Expand view


METHOD KeyCount() CLASS TXBrowse

   TRY
      if Empty( ::aFilter )
         ::nLen   := Eval( ::bKeyCount )
      else
         ::nLen   := Len( ::aFilter )
      endif
      ::lClosed   := .f.

   CATCH
      ::nLen      := 0
      ::lClosed   := .t.
   END


   if ::oVScroll != nil
      ::VSetRange( 1, ::nLen )

      if !::lSqlRDD
        ::VUpdatePos()
      endif
   endif

return ::nLen


 
Saludos / Regards,

FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
MOISES
 
Posts: 838
Joined: Wed Aug 22, 2007 10:09 am


Return to FiveWin para Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 33 guests