FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour FWH 1408 BtnBmp upgrade
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM

FWH 1408 BtnBmp upgrade

Posted: Wed Oct 08, 2014 08:26 PM
Antonio

I just upgraded from FWH 1203 to 1408 and got this BtnBmp error .. I have no clue what this error means or how to fix it. The code runs just fine under FWH 1203.

When the window paints it seems to stop on this button code:
Code (fw): Select all Collapse
REDEFINE BTNBMP oBtn1 ID 147 PROMPT "     Create "+CRLF+"     New "+CRLF+"     Repair " ;
                RESOURCE "PLUS","DPLUS","DPLUS" LEFT ;
                of oWork 2007 ;
                ACTION ( _Roview( "A",oWnd,oLbx,oWndChild,oRsRepair,@nRadSt1,oRadSt1,;
                                   @nRadSort,oRadSort  ))


I re-compiled the BtnBmp.prg from FWH1203 into my program to show you the screen shot ..


I know much has been recently done with the BtnBmp class .. hopefully there is a quick fix ?

Thanks
Rick Lipkin

Error.Log
Code (fw): Select all Collapse
Application
===========
   Path and name: C:\Fox\SaLite\Saw32.Exe (32 bits)
   Size: 5,007,360 bytes
   Compiler version: xHarbour 1.2.3 Intl. (SimpLex) (Build 20131030)
   FiveWin  Version: FWHX 14.08
   Windows version: 5.1, Build 2600 Service Pack 3

   Time from start: 0 hours 1 mins 33 secs 
   Error occurred at: 10/08/2014, 16:21:49
   Error description: Error BASE/1073  Argument error: <
   Args:
     [   1] = U   
     [   2] = N   22

Stack Calls
===========
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3291 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 420 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 23 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINTCAPTION( 1249 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:PAINT( 1339 )
   Called from: .\source\classes\BTNBMP.PRG => (b)TBTNBMP:TBTNBMP( 123 )
   Called from:  => TBTNBMP:DISPLAY( 0 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1699 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1429 )
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 02:26 AM
Mr Rick

This is fixed in 14.09 to be released.

Please make the following correction in the Method PaintCaption:

This error occurs in Method PaintCaption() in the block of code between "if lMultiline" and "else"

Please substitute the entire block of code with:
Code (fw): Select all Collapse
      if lMultiLine
         nMaxWidth = 0
         cWord = cStrWord( ::cCaption, @nOffset, CRLF )

         while nOffset < Len( ::cCaption )
            nMaxWidth = Max( nMaxWidth,;
                             Len( cWord2 := cStrWord( ::cCaption, @nOffset, CRLF ) ) )
            if Len( cWord ) < nMaxWidth
              cWord = cWord2
            endif
         end

         nLine = MLCount( ::cCaption )
         nTxtHeight = GetTextHeight( ::hWnd, ::hDC ) * nLine
         nTxtTop    = ::nHeight / 2 - nTxtHeight / 2
         nMaxWidth  = GetTextWidth( 0, cWord, ::oFont:hFont )
         nTxtLeft   = ::nWidth / 2 - nMaxWidth / 2
         nTxtRight  = ::nWidth / 2 + nMaxWidth / 2
      else
Regards



G. N. Rao.

Hyderabad, India
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 02:43 AM

I sent you an email. Please confirm receipt.

Regards



G. N. Rao.

Hyderabad, India
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 06:19 AM

Rick,

I just emailed you the FWH 14.09 (to be published real soon) libs :-)

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 01:03 PM

Antonio and Rao

Thank you BOTH very much .. I did get the libs and have just downloaded them as well as the BtnBmp.prg..

Results:

1) Antonio, the new libs did not fix the BtnBmp error, however, the BtnBmp.prg replacement that Rao sent works great!

2) The xBrowse error when tabbing thru EDIT_LISTBOX still exists.

I REALLY appreciate your quick response!!

Rick Lipkin

:D

Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 01:08 PM

We shall ensure to include the btnbmp.prg I sent you in the next release.
We shall also fix the EDIT_LISTBOX problem soon. This has been there for long but did not come to our notice so far.

Regards



G. N. Rao.

Hyderabad, India
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM

Re: FWH 1408 BtnBmp upgrade

Posted: Thu Oct 09, 2014 01:31 PM

Rao

Thank you VERY Much!

Rick Lipkin

Continue the discussion