MENUITEM with BLOCK command executed TWICE. (SOLVED)

Re: MENUITEM with BLOCK command executed TWICE.

Postby Horizon » Mon May 31, 2021 5:28 pm

:!:
Regards,

Hakan ONEMLI

Harbour & MSVC 2022 & FWH 23.04
Horizon
 
Posts: 1288
Joined: Fri May 23, 2008 1:33 pm

Re: MENUITEM with BLOCK command executed TWICE.

Postby Antonio Linares » Tue Jun 01, 2021 9:48 am

Dear Hakan,

In menu.prg please make these changes: (in the "else")

line 1574:
Code: Select all  Expand view
        if ::lPopup
            ::oMenuItemPopup = oMenuItem
         else  
            if ValType( oMenuItem:bBlock ) == "B"
               if oMenuItem:bWhen != nil .and. ! Eval( oMenuItem:bWhen, oMenuItem )
                  return nil
               endif
               ::oLastItem = oMenuItem
               if ::lPopup
                  ::oMenuItemPopup = oMenuItem
               endif
               Eval( oMenuItem:bBlock, oMenuItem )
            endif
         endif


Your example works fine with these changes

These changes will be included in the next FWH build
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41340
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: MENUITEM with BLOCK command executed TWICE.

Postby Horizon » Tue Jun 01, 2021 11:20 am

Antonio Linares wrote:Dear Hakan,

In menu.prg please make these changes: (in the "else")

line 1574:
Code: Select all  Expand view
        if ::lPopup
            ::oMenuItemPopup = oMenuItem
         else  
            if ValType( oMenuItem:bBlock ) == "B"
               if oMenuItem:bWhen != nil .and. ! Eval( oMenuItem:bWhen, oMenuItem )
                  return nil
               endif
               ::oLastItem = oMenuItem
               if ::lPopup
                  ::oMenuItemPopup = oMenuItem
               endif
               Eval( oMenuItem:bBlock, oMenuItem )
            endif
         endif


Your example works fine with these changes

These changes will be included in the next FWH build


Hi Antonio,

I use unmodifed fwh libs. Can you please send me change libs.

Thank you.
Regards,

Hakan ONEMLI

Harbour & MSVC 2022 & FWH 23.04
Horizon
 
Posts: 1288
Joined: Fri May 23, 2008 1:33 pm

Re: MENUITEM with BLOCK command executed TWICE.

Postby Antonio Linares » Tue Jun 01, 2021 11:22 am

Hakan,

What C compiler do you use ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41340
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: MENUITEM with BLOCK command executed TWICE.

Postby Horizon » Tue Jun 01, 2021 11:34 am

Antonio Linares wrote:Hakan,

What C compiler do you use ?


Harbour & MSVC 2019 & FWH 21.02
Regards,

Hakan ONEMLI

Harbour & MSVC 2022 & FWH 23.04
Horizon
 
Posts: 1288
Joined: Fri May 23, 2008 1:33 pm

Re: MENUITEM with BLOCK command executed TWICE.

Postby Antonio Linares » Tue Jun 01, 2021 11:58 am

Already sent to your email
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41340
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: MENUITEM with BLOCK command executed TWICE.

Postby Horizon » Tue Jun 01, 2021 1:30 pm

Antonio Linares wrote:Already sent to your email


Thank you Antonio,

It solved my problem.
Regards,

Hakan ONEMLI

Harbour & MSVC 2022 & FWH 23.04
Horizon
 
Posts: 1288
Joined: Fri May 23, 2008 1:33 pm

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Silvio.Falconi and 8 guests