FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Show a Diabled icon for Get\Action
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Show a Diabled icon for Get\Action
Posted: Tue May 06, 2014 02:40 PM
To All

I would like to be able to show a disabled icon, much like on a BtnBmp where, when the GET is disabled, there is an alternate bitmap to show on the get.

At this point, I can disable the GET, but there is no way to show an alternate Bitmap to reinforce the disabled control. Any suggestions would be welcome.

Rick Lipkin

Code (fw): Select all Collapse
REDEFINE GET oEmployeeName var cEmployeeName ID 132 of oDlg BITMAP "find" ; // add a second bitmap for disabled
      When nRad = 1 ;
      Action ( StafGet( cMode,@cEmployeeName,oEmployeeName,@nRate,oRate,;
                              @nStaffEid,oHours,"FIELD",xAe,;
                              oBtn1,oBtn2,oBtn3 ),;
              _ReCalc(nRate,nHours,@nEfee,oEfee,@nCfee,oCfee,@nTravel,oTravel,@nOther,oOther,@nTotal,oTotal ) ) UPDATE
      oEmployeeName:lAdjustBtn := .t.
      oEmployeeName:bKeyDown:= {|nK| if( nK==VK_RETURN,StafGet( cMode,@cEmployeeName,oEmployeeName,@nRate,oRate,;
                              @nStaffEid,oHours,"FIELD",xAe,;
                              oBtn1,oBtn2,oBtn3 ) , ) }


Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Show a Diabled icon for Get\Action
Posted: Wed May 07, 2014 12:44 AM

Rick,

You could disable the button doing:

oGet:oBtn:Disable() (later on oGet:oBtn:Enable())

also you can change its bitmap doing:

oGet:oBtn:LoadBitmap( cBmpName )
oGet:oBtn:Refresh()

regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion