動態隱藏/顯示選擇螢幕
這個程式比較簡單,也沒太多的知識點,在此就不介紹了,程式如下:
*&---------------------------------------------------------------------*
*& Report ZTEST_SELECT_SCREEN
*&
*&---------------------------------------------------------------------*
*& Create By : flying
*& Create Date : 2009-11-25
*& descriptions : 測試隱藏/顯示選擇螢幕
*&---------------------------------------------------------------------*
REPORT ZTEST_SELECT_SCREEN.
tables: mbew,
ekpo,
mseg.
*----------------------------------------------------------------------*
* selection-screen
* 選擇螢幕
*
*----------------------------------------------------------------------*
*** 定義選擇表的選擇螢幕
selection-screen begin of block blk1 with frame title text-000.
parameters: r1 radiobutton group grp user-command sele default 'X', "這裡沒有user-command sele會不起作用的
r2 radiobutton group grp,
r3 radiobutton group grp.
selection-screen end of block blk1.
*** 定義表mbew的選擇螢幕
selection-screen begin of block blk2 with frame title text-001.
parameters: p_werks like mbew-bwkey modif id m1. "設定螢幕元素的組,方便操作
select-options: s_matnr for mbew-matnr modif id m1.
selection-screen end of block blk2.
*** 定義表ekpo的選擇螢幕
selection-screen begin of block blk3 with frame title text-002.
parameters: p_werks1 like ekpo-werks modif id m2.
select-OPTIONS s_matnr1 for ekpo-matnr modif id m2.
selection-screen end of block blk3.
*** 定義表mseg的選擇螢幕
selection-screen begin of block blk4 with frame title text-003.
parameters: p_werks2 like mseg-werks modif id m3.
select-options s_matnr2 for mseg-matnr modif id m3.
selection-screen end of block blk4.
*-----------------------------------------------------------------------*
* at selection-screen output
* 螢幕輸出之前處理
*
*-----------------------------------------------------------------------*
at selection-screen output.
loop at screen.
case screen-group1. "螢幕組
when 'M1'.
if r1 eq 'X'.
screen-active = 1. "設定螢幕顯示
else.
screen-active = 0. "設定螢幕隱藏
endif.
when 'M2'.
if r2 eq 'X'.
screen-active = 1.
else.
screen-active = 0.
endif.
when 'M3'.
if r3 eq 'X'.
screen-active = 1.
else.
screen-active = 0.
endif.
endcase.
modify screen. "修改選擇螢幕屬性
endloop.
執行效果如下:
*&---------------------------------------------------------------------*
*& Report ZTEST_SELECT_SCREEN
*&
*&---------------------------------------------------------------------*
*& Create By : flying
*& Create Date : 2009-11-25
*& descriptions : 測試隱藏/顯示選擇螢幕
*&---------------------------------------------------------------------*
REPORT ZTEST_SELECT_SCREEN.
tables: mbew,
ekpo,
mseg.
*----------------------------------------------------------------------*
* selection-screen
* 選擇螢幕
*
*----------------------------------------------------------------------*
*** 定義選擇表的選擇螢幕
selection-screen begin of block blk1 with frame title text-000.
parameters: r1 radiobutton group grp user-command sele default 'X', "這裡沒有user-command sele會不起作用的
r2 radiobutton group grp,
r3 radiobutton group grp.
selection-screen end of block blk1.
*** 定義表mbew的選擇螢幕
selection-screen begin of block blk2 with frame title text-001.
parameters: p_werks like mbew-bwkey modif id m1. "設定螢幕元素的組,方便操作
select-options: s_matnr for mbew-matnr modif id m1.
selection-screen end of block blk2.
*** 定義表ekpo的選擇螢幕
selection-screen begin of block blk3 with frame title text-002.
parameters: p_werks1 like ekpo-werks modif id m2.
select-OPTIONS s_matnr1 for ekpo-matnr modif id m2.
selection-screen end of block blk3.
*** 定義表mseg的選擇螢幕
selection-screen begin of block blk4 with frame title text-003.
parameters: p_werks2 like mseg-werks modif id m3.
select-options s_matnr2 for mseg-matnr modif id m3.
selection-screen end of block blk4.
*-----------------------------------------------------------------------*
* at selection-screen output
* 螢幕輸出之前處理
*
*-----------------------------------------------------------------------*
at selection-screen output.
loop at screen.
case screen-group1. "螢幕組
when 'M1'.
if r1 eq 'X'.
screen-active = 1. "設定螢幕顯示
else.
screen-active = 0. "設定螢幕隱藏
endif.
when 'M2'.
if r2 eq 'X'.
screen-active = 1.
else.
screen-active = 0.
endif.
when 'M3'.
if r3 eq 'X'.
screen-active = 1.
else.
screen-active = 0.
endif.
endcase.
modify screen. "修改選擇螢幕屬性
endloop.
執行效果如下:
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/16794144/viewspace-681160/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- jqgrid動態顯示,隱藏指定列
- 在 Laravel 中動態 隱藏 / 顯示 API 欄位LaravelAPI
- mac顯示隱藏檔案,取消顯示隱藏檔案Mac
- Android -- 工具類(七):[ScreenUtil] (截圖,獲取螢幕寬高,顯示、隱藏虛擬鍵盤,調節螢幕亮度)Android
- CSS點選隱藏和顯示div效果CSS
- QT居中螢幕顯示QT
- iOS 隱藏&顯示tabBariOStabBar
- Mac顯示和隱藏“隱藏檔案”命令Mac
- 動態控制C4C UI元素的顯示和隱藏UI
- element-plus el-table 動態設定列顯示隱藏
- FloatingActionButton在RecycleView中滑動隱藏顯示View
- jQuery動畫的顯示與隱藏效果jQuery動畫
- jQuery動畫的顯示與隱藏效果!jQuery動畫
- Android 顯示、隱藏狀態列和導航欄Android
- LCD螢幕顯示PNG影像
- jQuery 效果 – 隱藏和顯示jQuery
- Mac顯示/不顯示隱藏檔案教程!Mac
- Selenium 隱式等待與顯示等待的選擇
- 點選同一按鈕顯示隱藏切換
- excel隱藏的部分如何顯示出來 excel裡面怎麼顯示隱藏部分Excel
- MACOS 如何顯示隱藏檔案Mac
- 區塊的顯示和隱藏
- 【macOS】顯示/隱藏 指定檔案Mac
- OSX中隱藏和顯示[隱藏檔案]的命令列命令列
- 直播app開發,點選螢幕時顯示進度條APP
- ElementUI側邊欄導航選單隱藏顯示問題UI
- steam隱藏的遊戲怎麼顯示出來 steam隱藏顯示遊戲方法介紹遊戲
- CSS——文字超出隱藏顯示省略號CSS
- JavaScript 設定div顯示與隱藏JavaScript
- mac 隱藏檔案顯示 快捷鍵Mac
- javascript隱藏和顯示div的方法JavaScript
- jQuery 實現顯示與隱藏效果jQuery
- Android 眼睛 顯示隱藏密碼(ImageView)Android密碼View
- JavaScript動畫方式控制div元素的隱藏和顯示JavaScript動畫
- jQuery實現簡單點選隱藏和點選顯示列表的功能jQuery
- 實現單擊一級選單顯示或隱藏二級選單
- Omdia:大尺寸螢幕顯示驅動晶片緊缺將是長期的常態晶片
- win10 如何顯示隱藏資料夾_win10 如何顯示隱藏的資料夾Win10
- vue 滑鼠移入顯示圖示 ,滑鼠移出隱藏圖示Vue