FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Unknown PickColor()
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Unknown PickColor()
Posted: Sun Aug 27, 2023 12:37 PM
Hi,

I tried to compile the testbtnclr.prg example, however, I received a message about the presence of an unknown PickColor() function. Why?

FWH 23.07
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
Re: Unknown PickColor()
Posted: Sun Aug 27, 2023 08:43 PM

It Is no function

It Is a class inside tbtnclr class

The call for the tpickcolor Is explain on the tbtnclr source code.

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 1772
Joined: Thu Sep 05, 2019 05:32 AM
Re: Unknown PickColor()
Posted: Mon Aug 28, 2023 10:49 AM
hi,
Natter wrote:unknown PickColor() function.
it seems not in LIB, but it is under c:\fwh\source\function\pickcolor.prg
greeting,

Jimmy
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Re: Unknown PickColor()
Posted: Mon Aug 28, 2023 12:02 PM
Yes, I see. It just appears in the example as a public function, which is why I asked :?
Code (fw): Select all Collapse
@ 30,10 BTNCLR oBtnColor SIZE 45,25 of oDlg PIXEL COLORSEL nColor ;
             ACTION  (oBtnColor:nColorSel:= PickColor( nColor, oBtnColor),;
                      oBtnColor:refresh())
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
Re: Unknown PickColor()
Posted: Mon Aug 28, 2023 12:27 PM

Go go the class

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 1772
Joined: Thu Sep 05, 2019 05:32 AM
Re: Unknown PickColor()
Posted: Mon Aug 28, 2023 12:54 PM
hi Natter,
Natter wrote:Yes, I see. It just appears in the example as a public function, which is why I asked :?
it "seems" me that Function PickColor() is not used any more (old Sample)
now we have CLASS Class TPickerColor() as Silvio say
greeting,

Jimmy
Posts: 7317
Joined: Thu Oct 18, 2012 07:17 PM
Re: Unknown PickColor()
Posted: Wed Sep 06, 2023 09:52 AM
Try It please


Code (fw): Select all Collapse
Function PickColor(nColor,oControl)
local oPick

oPick:= TPickerColor():New(nColor,oControl)
oPick:Dialog()

IF  oPick:Activate()
    IF oPick:oDlgPickColor:nresult == IDOK
      return oPick:nClrReturn
   endif
Endif

RETURN NIL
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com

Continue the discussion