BtnBmp.. I not understood this error

BtnBmp.. I not understood this error

Postby Silvio.Falconi » Mon Oct 03, 2022 7:47 pm

I have this error ....

Code: Select all  Expand view  RUN
Error occurred at: 10/03/22, 21:36:40
   Error description: Error BASE/1004  No exported method: ACTIVATE
   Args:
     [   1] = C   yellow
     [   2] = N   32
     [   3] = N   4
     [   4] = O   TDIALOG
     [   5] = L   .F.

Stack Calls
===========
   Called from:  => ACTIVATE( 0 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:LBUTTONUP( 989 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1845 )
   Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 2051 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3560 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 304 )
   Called from: test.prg => TESTBUTTON( 30 )




and on dialog I have only

Code: Select all  Expand view  RUN
#include "FiveWin.ch"


Function TestButton()

local oDlg
local oBtn1
local nColor1:=CLR_GRAY
local nColor2:=CLR_GRAY


DEFINE DIALOG oDlg SIZE 500,400  PIXEL TRUEPIXEL RESIZABLE;
   TITLE "Tavolozza colori numeri"


     @ 50,50 BTNBMP oBtn1  ;
      SIZE 50,50 PIXEL OF oDlg FLAT NOBORDER ;
      COLOR nColor1,nColor2 ;
       ACTION ( ::oPopup := { |oBtn| PicKColors(oBtn,oDlg,,"gray") }, ;
                  ::ShowPopUp(), ;
                  ::oPopup := nil )



ACTIVATE DIALOG oDLG  CENTERED
return  nil



//----------------------------------------------------------------//

Function PicKColors(ocontrol,oParent,lHex,cColore)
Local oDlgSel,oPanel
Local aColors := {}
Local aReturnvalue:={}
Local nSelection:= 1

DEFAULT  lHex := .F.

DEFINE DIALOG oDlgSel SIZE 400,200 PIXEL
 oDlgSel:nStyle    = nOR( WS_CHILD, WS_BORDER, WS_VISIBLE,WS_POPUP )

ACTIVATE DIALOG oDlgSel  CENTERED      

RETURN NIL



 


PickColors is mine function you can use also choosecolor()

I need a btnbmp with popup button but the popup must open My function where is a small dialog as this

Image

then I select the color the procedure make that error , but the error is come out also with choosecolor()


Image

the black arrow come out then I press the button , why ?
Last edited by Silvio.Falconi on Sat Oct 15, 2022 9:23 pm, edited 1 time in total.
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 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
User avatar
Silvio.Falconi
 
Posts: 7072
Joined: Thu Oct 18, 2012 7:17 pm

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 65 guests