Problem in barmenu in FWH 20.12

User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12 (solved)

Post by driessen »

Mr. C. Navarro,

Thank you very much. I added the corrected file menu.prg to my application and the problem is solved.
It will be definite in the next version, I presume.

Thank you once again.

In case you rebuild the lib-file, please can you send it to me? Thanks.
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Problem in barmenu in FWH 20.12 (solved)

Post by cnavarro »

Yes, surely a 20.12.1 version will be released
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Re: Problem in barmenu in FWH 20.12 (solved)

Post by Antonio Linares »

Yes, we are going to publish a FWH 20.12.1 build

many thanks to all
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12

Post by driessen »

I just wanted to tell you all that I experienced another error in the tMenu class.

I have implemented the tMenu class of FWH 20.08 into my application.
Then I have rebuild my application with FWH 20.08.

Sometimes I get this error : Error BASE/1004 No exported method: EVAL

I need to roll back to FWH 20.08 to run my application without any problems.

I just wanted to let you know about this problem.

Have a nice weekend.
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Problem in barmenu in FWH 20.12

Post by cnavarro »

Please, Can you send me the error.log you get?
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12

Post by driessen »

Cristobal,

Thank you very much. I just send you an e-mail.

Regards.
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Problem in barmenu in FWH 20.12

Post by cnavarro »

It seems that the error is obtained when clicking the right mouse button on an xbrowse, is it?
Have you defined a menu when you press that button?
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12

Post by driessen »

That is a correct conclusion, Cristobal.
A pulldownmenu is defined when clicking the right mouse button. But in this case, I just use wbrowse.
Thanks.
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Problem in barmenu in FWH 20.12

Post by cnavarro »

Please, send me your menu defined
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12

Post by driessen »

This is my code (I hope you can understand it) :

Code: Select all

******************************************************************************

STATIC FUNCTION DsBldPopUp(fCol,gCol)

   LOCAL OldPar := {ALIAS(),INDEXORD(),RECNO()}

   LOCAL cRet   := .F.
   LOCAL dRet   := .F.

   DeleteObject(pMenu)
   MEMORY(-1)
   TMenuItem():New():nInitId := 20000
   SYSREFRESH()

   pMenu := NIL

   MENU pMenu POPUP

        SELECT MENT
        SET ORDER TO 5
        GO TOP
        DO WHILE !EOF()
           IF MENT->MNPOPUP = ShowArr[ShowLbx:nAt,17,1] .OR. MENT->MNPOPUP = 15
              DO CASE
                 CASE MENT->MNSOORT = 1 ; DsMenuVul(dRet) ; dRet := .F. ; MENU
                 CASE MENT->MNSOORT = 2
                      SELECT DOC
                      SET ORDER TO 3
                      SEEK(VAL(MENT->MNDOC))
                      IF FOUND()
                         IF (MENT->MNPOPUP = 15 .AND. ShowArr[ShowLbx:nAt,17,1] <> 13) .OR. ;
                            (MENT->MNPOPUP = ShowArr[ShowLbx:nAt,17,1] .AND. ;
                             (DOC->DOCMAIL = 11 .OR. ;
                              ((ShowArr[ShowLbx:nAt,17,2] = "1" .AND. (DOC->DOCMAIL = 2 .OR. DOC->DOCMAIL = 5 .OR. DOC->DOCMAIL = 6 .OR. DOC->DOCMAIL = 9)) .OR. ;
                               (ShowArr[ShowLbx:nAt,17,2] = "2" .AND. (DOC->DOCMAIL = 3 .OR. DOC->DOCMAIL = 5 .OR. DOC->DOCMAIL = 7 .OR. DOC->DOCMAIL = 9)) .OR. ;
                               (ShowArr[ShowLbx:nAt,17,2] = "3" .AND. (DOC->DOCMAIL = 4 .OR. DOC->DOCMAIL = 5 .OR. DOC->DOCMAIL = 8 .OR. DOC->DOCMAIL = 9)) .OR. ;
                               (ShowArr[ShowLbx:nAt,17,2] <> "1" .AND.ShowArr[ShowLbx:nAt,17,2] <> "2" .AND.ShowArr[ShowLbx:nAt,17,2] <> "3"))))
                            DsMenuVul(dRet,MENT->MNPOPUP,fCol,gCol) ; dRet := .F.
                         ENDIF
                      ENDIF
                      SELECT MENT
                 CASE MENT->MNSOORT = 3 ; dRet := .T.
                 CASE MENT->MNSOORT = 4 ; dRet := .F. ; ENDMENU
              ENDCASE
              cRet := .T.
           ENDIF
           SKIP
        ENDDO
        
   ENDMENU

   SELECT(OldPar[1])
   SET ORDER TO OldPar[2]
   GOTO OldPar[3]

RETURN(cRet)

******************************************************************************

STATIC PROCEDURE DsMenuVul(mRet,mTel,hCol,iCol)

   LOCAL cActie := ""

   DEFAULT(mTel,0)
   DEFAULT(hCol,0)
   DEFAULT(iCol,0)

   IF mRet ; SEPARATOR ; ENDIF

   IF !EMPTY(cActie := MENT->MNACTIE)
      IF hCol < iCol
         cActie := ALLTRIM(cActie) + ",OpenBase(.T.),EndSub(.T.,,.T.)}"
      ELSE
         cActie := LEFT(ALLTRIM(cActie),LEN(ALLTRIM(cActie))-1) + ",,,,,,," + IF(mTel=1,".F.",".T.") + ",ShowLbx:nAt),OpenBase(.T.),EndSub(.T.,,.T.)}"
      ENDIF
      cActie := "{|| ToonWindow(),StartSub(.T.,,.T.)," + ALLTRIM(cActie)
      MENUITEM (ALLTRIM(IF(EMPTY(MENT->MNPOPTXT),MENT->MNTEKST,MENT->MNPOPTXT)) + IF(!EMPTY(MENT->MNFKEY),CHR(9)+ALLTRIM(MENT->MNFKEY),"")) BLOCK ({|| TvActie := cActie})
   ELSE
      MENUITEM (ALLTRIM(IF(EMPTY(MENT->MNPOPTXT),MENT->MNTEKST,MENT->MNPOPTXT)))
   ENDIF

RETURN

******************************************************************************
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Problem in barmenu in FWH 20.12

Post by cnavarro »

Please, put your function DSPOPUP
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
driessen
Posts: 1239
Joined: Mon Oct 10, 2005 11:26 am
Location: Genk, Belgium

Re: Problem in barmenu in FWH 20.12

Post by driessen »

Code: Select all

******************************************************************************

STATIC PROCEDURE DsPopUp(dRow,dCol,eCol)

   LOCAL OldPar   := {ALIAS(),INDEXORD(),RECNO()}

   LOCAL cHoogte  := ShowLbx:nHeight
   LOCAL cRij     := 0

   SELECT US
   SET ORDER TO 3
   SEEK(UPPER(nUser))

   cHoogte := (cHoogte - IF(&("US->UDOSOZK"+CheckTermServ())=0,17,&("US->UDOSOZK"+CheckTermServ()))) / (IF(&("US->UDOSGK" +CheckTermServ())=1,30,42) - IF(&("US->UDOSIND"+CheckTermServ()),1,0))
   cRij    := ROUND(((dRow - IF(&("US->UDOSOZK"+CheckTermServ())=0,17,&("US->UDOSOZK"+CheckTermServ()))) / cHoogte) + IF(&("US->UDOSOZC"+CheckTermServ())=0,0.75,&("US->UDOSOZC"+CheckTermServ())),0) - ShowLbx:nRowPos

   IF cRij > 0
      FOR i = 1 TO cRij
          ShowLbx:GoDown()
      NEXT
   ELSE
      FOR i= cRij TO -1
          ShowLbx:GoUp()
      NEXT
   ENDIF

   SYSREFRESH()

   IF ShowArr[ShowLbx:nAt,5] .AND. DsBldPopUp(dCol,eCol)
      ActieTV := .F.
      ACTIVATE POPUP pMenu WINDOW ShowLbx AT dRow,dCol
      pMenu:End()
      ActieTV := .T.
   ENDIF

   SELECT(OldPar[1])
   SET ORDER TO OldPar[2]
   GOTO OldPar[3]

RETURN

******************************************************************************
Regards,

Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Post Reply