Problemas con la versión 7.12

Problemas con la versión 7.12

Postby fgondi » Tue Dec 18, 2007 12:01 pm

Me he encontrado los siguientes problemas en la versión 7.12 y como los he solucionado

1.- TCombobox. Genera un error al pulsar VK_DEL si la lista de elementos (::aItems) son 0

Code: Select all  Expand view
METHOD KeyChar( nKey, nFlags ) CLASS TComboBox
   local nNewAT := 0, nOldAT := ::nAT, uItem

   do case
      case nKey = 32   // VK_DELETE (DO NOT WORK!)
           ::cSearchKey = ""
           nNewAt = 1
           uItem  = if( len(::aItems)>=nNewAt, ::aItems[ nNewAt ], '' )  //...  Nuevo.fgondi
           
      case nKey = VK_BACK
           ::cSearchKey = Left( ::cSearchKey, Len( ::cSearchKey ) - 1 )
           
      case nKey = 190
           nKey = 0
           ::cSearchKey += "."
           
      otherwise
           ::cSearchKey += Upper( Chr( nKey ) )
   endcase
   
   if Empty( uItem )
      if nNewAt == 0
         nNewAt = AScan( ::aItems, {|x| Upper(x) = ::cSearchKey } )
         if nNewAt > 0 //.and. Len( ::aItems ) <= nNewAt //... Nuevo.fgondi
            uItem = ::aItems[ nNewAt ]
         elseif len(::aItems)>=Max( ::nAT, 1 )   //... Nuevo.fgondi
           uItem = ::aItems[ Max( ::nAT, 1 ) ]   //... Nuevo.fgondi
         endif
      elseif len(::aItems)>=Max( nNewAt, 1 )     //... Nuevo.fgondi
         uItem = ::aItems[ Max( nNewAt, 1) ]
      endif
   endif
...


2.- TDtPicke. Genera un error al definir el objeto si la variable (uVar) esta definida a null. No se si es un error pero la clase TGet lo acepta.

Code: Select all  Expand view
METHOD SetDate( dDate, lEmpty ) INLINE if( Valtype(dDate)<>'D', dDate := ctod(''), ),; //... Nuevo.fgondi
                                  SetDatePick( ::hWnd, Year( dDate ),;
                                  Month( dDate ), Day( dDate ),;
                                  If( ( lEmpty != nil .and. lEmpty ) .or. Empty( dDate ),;
                                  1, 0 ) )


3. TTmPicke. No controla correctamente la hora vacia (checkbox a su izquierda)

Code: Select all  Expand view
METHOD GetTime()        INLINE if( Empty(GetDatePick( ::hWnd )), space(6), GetTimePick(::hWnd) ) //... Nuevo.fgondi

Code: Select all  Expand view
METHOD SetTime( cHour ) CLASS TTimePick
   local cShow, nHora, nMinut, nSeg
   cShow  := if( Empty(cHour), Hora(), cHour )
   dShow := if( Empty(cHour), Date(), ctod('') ) //... Nuevo.fgondi
   nHora  := Val(left(cShow, 2))
   if At(':', cShow)<>0
     nMinut := Val(SubStr(cShow, 4, 2))
   else
     nMinut := Val(SubStr(cShow, 3, 2))
   endif
   nSeg   := Val(Right(cShow, 2))
   SetTimePick( ::hWnd, Year( dShow), Month( dShow ), Day( dShow ),;
                nHora, nMinut, nSeg, 0 ) //... Nuevo.fgondi
   if Empty(cHour)
     SetTimePick( ::hWnd, Year( dShow ), Month( dShow ), Day( dShow ),;
                  nHora, nMinut, nSeg, 1 ) //... Nuevo.fgondi
   endif
return self
Un saludo
Fernando González Diez
ALSIS Sistemas Informáticos
User avatar
fgondi
 
Posts: 694
Joined: Fri Oct 07, 2005 6:58 am
Location: Palencia, España

Postby Antonio Linares » Tue Dec 18, 2007 2:21 pm

Fernando,

Gracias! :-)

Vamos a revisarlo y te comentamos
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41390
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Problemas con la versión 7.12

Postby FiveWiDi » Tue Dec 18, 2007 6:48 pm

Muchas gracias Fernando,

Ahora no recuerdo si ha sido Melchor o Gaspar que me ha dicho que pronto tendré yo los mismos problemas (y con mucho gusto por cierto).

Saludos y Felices Fiestas
Carlos G.
FiveWiDi
 
Posts: 1083
Joined: Mon Oct 10, 2005 2:38 pm


Return to FiveWin para Harbour/xHarbour

Who is online

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