Page 1 of 1

erase button on ribbonbar- Resolved

Posted: Fri May 17, 2019 9:23 am
by Silvio.Falconi
I must erase 4 button on a ribbonbar on a group to recreate it each time I open a function

I made

Code: Select all

IF oApp():oNavigaZoom != nil
         oApp():oNavigaZoom:end()
         For n= 1 to 4
            oBtnNav[n]:destroy()  //end()
            next
         oApp():oNavigaZoom := oApp():oReBar:AddGroup( 300, "Navigazione", 1,,, )
        else
         oApp():oNavigaZoom := oApp():oReBar:AddGroup( 300, "Navigazione", 1,,, )
      Endif

 @ 9,5 ADD BUTTON oBtnNav[1]......

and try also with

I

Code: Select all

F oApp():oNavigaZoom != nil
                AEVal( oBtnNav, { | oBtn | oBtn:end() } )
         oApp():oNavigaZoom:end()
         oApp():oNavigaZoom := oApp():oReBar:AddGroup( 300, "Navigazione", 1,,, )
        else
         oApp():oNavigaZoom := oApp():oReBar:AddGroup( 300, "Navigazione", 1,,, )
      Endif






but it make error on second time I try to end the button and recreate it

Re: erase button on ribbonbar

Posted: Fri May 17, 2019 10:39 am
by Silvio.Falconi
Resolved

Code: Select all

For n= 1 to Len( oApp():oNavigaZoom:aControls)
            oApp():oNavigaZoom:aControls[n]:end()
           next