欢迎来到天天文库
浏览记录
ID:40491683
大小:325.56 KB
页数:5页
时间:2019-08-03
《abap中实现在屏幕上显示图片》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、1、SE78上传图片到服务器,图片只能是bmp格式的点击预览,查看是否上传成功这里我们将图片对象命名为sapclub2、新建程序1.REPORT ydamon_103.2.3.CALLSCREEN9000.4.*&---------------------------------------------------------------------*5.*& Module status_9000 OUTPUT6.*&---------------------------------------------------------------------*7.
2、* text8.*----------------------------------------------------------------------*9.MODULEstatus_9000OUTPUT.10. DATA:w_linesTYPEi.11. TYPESpict_line(256)TYPEc.12. DATA:13. containerTYPEREFTOcl_gui_custom_container,14. editorTYPEREFTOcl_gui_textedit,15. pictureTYPEREFTOcl_gui_pictur
3、e,16. pict_tabTYPETABLEOFpict_line,17. url(255)TYPEc.18. DATA:graphic_url(255).19. DATA:BEGINOFgraphic_tableOCCURS0,20. line(255)TYPEx,21. ENDOFgraphic_table.22. DATA:l_graphic_convTYPEi.23. DATA:l_graphic_offsTYPEi.24. DATA:graphic_sizeTYPEi.25. DATA:l_graphic_xstrTYPEx
4、string.26. .27. CALLMETHODcl_gui_cfw=>flush.28. CREATEOBJECT:29. containerEXPORTINGcontainer_name='PICTURE_CONTAINER',30. pictureEXPORTINGparent=container.1. CALLMETHODcl_ssf_xsf_utilities=>get_bds_graphic_as_bmp2. EXPORTING3. p_object ='GRAPHICS'4. p_name ='SAPCLUB'
5、 "这里是我们se78上传图片的命名名称5. p_id ='BMAP'6. p_btype ='BCOL'7. RECEIVING8. p_bmp =l_graphic_xstr9.* EXCEPTIONS10.* NOT_FOUND =111.* INTERNAL_ERROR=212.* others =313. .14. IFsy-subrc<>0.15.*MESSAGEIDSY-MSGIDTYPESY-MSGTYNUMBERSY-MSGNO16.* WIT
6、HSY-MSGV1SY-MSGV2SY-MSGV3SY-MSGV4.17. ENDIF.18. graphic_size=XSTRLEN(l_graphic_xstr).19. l_graphic_conv=graphic_size.20. l_graphic_offs=0.21. WHILEl_graphic_conv>255.22. graphic_table-line=l_graphic_xstr+l_graphic_offs(255).23. APPENDgraphic_table.24. l_graphic_offs=l_graphic_offs
7、+255.25. l_graphic_conv=l_graphic_conv-255.26. ENDWHILE.27. graphic_table-line=l_graphic_xstr+l_graphic_offs(l_graphic_conv).28. APPENDgraphic_table.29. CALLFUNCTION'DP_CREATE_URL'30. EXPORTING31. type ='IMAGE'32. subtype ='X-UNKNOWN'1. size =g
此文档下载收益归作者所有