登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

原来为了你

我的人生就是要一次次的超越

 
 
 

日志

 
 
 
 

进度条模板2  

2011-10-18 09:26:56|  分类: ABAP屏幕操作 |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |

*&---------------------------------------------------------------------*
*&      Form  schedule
*&---------------------------------------------------------------------*
form schedule using c_message type c i_percent type i.
  
datac_sche(204).

  
if i_percent <= or i_percent > 100 .
    c_sche 
'百分比错误!!!'.
  
else.
    
datac_percent(4),
    c_block
(6type c value '■■',
    i_blocklen 
type i,
    i_count 
type i,
    i_col 
type i,
    i_len 
type i,
    i_temp 
type i value 0,
    i_mod 
type i.
    i_blocklen 
strlenc_block ).
    c_percent 
i_percent.
    
condense c_percent.
    c_percent+3
(1) = '%'.
    c_sche 
c_percent.
    i_count 
i_percent / 4.
    
do i_count times.
      i_col 
= ( i_temp * i_blocklen 4.
      c_sche+i_col
(i_blocklen) = c_block.
      i_temp 
i_temp + 1.
    
enddo.
    i_len 
strlenc_message ).
    i_mod 
i_len mod 2.
    
if i_mod 1.
      i_len 
i_len + 1.
    
endif.
    
if i_len > 0.
      c_sche+4
(i_len) = c_message.
    
endif.
    i_len 
strlenc_sche ).
  
endif.
  
call function 'SAPGUI_PROGRESS_INDICATOR'
    
exporting
      percentage 
0
      
text       c_sche
    
exceptions
      
others     1.
endform" SCHEDULE


以下是调用这个form的示例程序
datai_prog  type i,
      i_prog2 
type i.

start
-of-selection.
  
do 100 times .
*    do 100000 times.
*      i_prog2 = i_prog2 + 1.
*    enddo.
    i_prog 
i_prog + 1.
*    write: / '' no-gap , i_prog no-gap , '次运行:',i_prog2.
    
perform schedule using '' i_prog"调用上面的INCLUDE显示进度
  
enddo.

  评论这张
 
阅读(359)| 评论(0)

历史上的今天

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2018