Problem with :moveColumn
Posted: Sun Oct 06, 2019 8:27 am
Hi everyone...
I have a problem with moving column in a browse, I had working with 1.9 version without problem but when I build the project with 2.0 the colummns don't move the same way.
When I click right button in a column it shows a menu that permit to move this column to right or left, but if I click againg, the selected column is not the column I'm clicking...
I've tried the Express 2.0 sample and it works like mine, don't work popperly. Only work with the first time. I've tried to refreshing and forcestable but i doesn't woth either.
Any idea?
Thanks
Daniel
Function code in the EXP20 Sample:
STATIC FUNCTION BrowseMenu( oBrowse )
STATIC soMenu, soBrowse
LOCAL GetList[0], i
IF Valtype(soMenu) # 'O' .OR. soMenu:status()<=0 .OR. soBrowse # oBrowse
IF Valtype(soMenu) = 'O'
soMenu := nil
ENDIF
soBrowse := oBrowse
DCSUBMENU soMenu
DCMENUITEM 'Move Column &Left' PARENT soMenu ACTION {||soBrowse:moveColumn(-1)}
DCMENUITEM 'Move Column &Right' PARENT soMenu ACTION {||soBrowse:moveColumn(1)}
DCMENUITEM SEPARATOR PARENT soMenu
DCMENUITEM 'Restore Defaults' PARENT soMenu ACTION {||soBrowse:restoreDefaults()}
DCREAD GUI ;
PARENT oBrowse ;
EXIT
ENDIF
RETURN soMenu
* --------------
STATIC FUNCTION BrowseMenuBlock( oBrowse )
RETURN {|x,y,z,o|o := BrowseMenu( oBrowse ), ;
o:popup( nil, x, 1 , ;
XBPMENU_PU_DEFAULT + XBPMENU_PU_MOUSE_RBDOWN ) }
* -------------
PROC appsys ; RETURN
I have a problem with moving column in a browse, I had working with 1.9 version without problem but when I build the project with 2.0 the colummns don't move the same way.
When I click right button in a column it shows a menu that permit to move this column to right or left, but if I click againg, the selected column is not the column I'm clicking...
I've tried the Express 2.0 sample and it works like mine, don't work popperly. Only work with the first time. I've tried to refreshing and forcestable but i doesn't woth either.
Any idea?
Thanks
Daniel
Function code in the EXP20 Sample:
STATIC FUNCTION BrowseMenu( oBrowse )
STATIC soMenu, soBrowse
LOCAL GetList[0], i
IF Valtype(soMenu) # 'O' .OR. soMenu:status()<=0 .OR. soBrowse # oBrowse
IF Valtype(soMenu) = 'O'
soMenu := nil
ENDIF
soBrowse := oBrowse
DCSUBMENU soMenu
DCMENUITEM 'Move Column &Left' PARENT soMenu ACTION {||soBrowse:moveColumn(-1)}
DCMENUITEM 'Move Column &Right' PARENT soMenu ACTION {||soBrowse:moveColumn(1)}
DCMENUITEM SEPARATOR PARENT soMenu
DCMENUITEM 'Restore Defaults' PARENT soMenu ACTION {||soBrowse:restoreDefaults()}
DCREAD GUI ;
PARENT oBrowse ;
EXIT
ENDIF
RETURN soMenu
* --------------
STATIC FUNCTION BrowseMenuBlock( oBrowse )
RETURN {|x,y,z,o|o := BrowseMenu( oBrowse ), ;
o:popup( nil, x, 1 , ;
XBPMENU_PU_DEFAULT + XBPMENU_PU_MOUSE_RBDOWN ) }
* -------------
PROC appsys ; RETURN