Insert picture in selection screen.
Hi,
Can some one suggest how to insert picture in selection screen?
Thanks
Deep
Hi,
I have inserted a picture in my classical report. According to the position where you want can be adjusted. If you know how to upload Logo in SMW0 then upload and just copy paste the code that i have shown will display the image.
DATA: docking TYPE REF TO cl_gui_docking_container,
picture_control_1 TYPE REF TO cl_gui_picture,
url(256) TYPE c .
DATA: query_table LIKE w3query OCCURS 1 WITH HEADER LINE,
html_table LIKE w3html OCCURS 1,
return_code LIKE w3param-ret_code,
content_type LIKE w3param-cont_type,
content_length LIKE w3param-cont_len,
pic_data LIKE w3mime OCCURS 0,
pic_size TYPE i.
* END OF DO NOT CHANGE----------------------*
FORMAT HOTSPOT ON.
DATA : sum(4) , num1(4) , num2(4).
PARAMETERS: A(4) DEFAULT '4' .
PARAMETERS: B(4) DEFAULT '5' .
DATA: ANSWER TYPE I.
ANSWER = A + B.
WRITE:/ ANSWER.
AT SELECTION-SCREEN OUTPUT.
PERFORM show_pic.
* PERFORM show_pic1.
START-OF-SELECTION.
*& Form show_pic
FORM show_pic.
DATA: repid LIKE sy-repid.
repid = sy-repid.
CREATE OBJECT picture_control_1 EXPORTING parent = docking.
CHECK sy-subrc = 0.
CALL METHOD picture_control_1->set_3d_border
EXPORTING
border = 5.
CALL METHOD picture_control_1->set_display_mode
EXPORTING
display_mode = cl_gui_picture=>display_mode_stretch.
CALL METHOD picture_control_1->set_position
EXPORTING
height = 90
left = 40
top = 30
width = 190.
*CHANGE POSITION AND SIZE ABOVE*****************
IF url IS INITIAL.
REFRESH query_table.
query_table-name = '_OBJECT_ID'.
*CHANGE IMAGE NAME BELOW UPLOADED IN SWO0******************
query_table-value = 'YREDDY'. "name which u have given in SMW0
APPEND query_table.
query_table-value = 'YLOGO'.
APPEND query_table.
*FORMAT HOTSPOT ON.
CALL FUNCTION 'WWW_GET_MIME_OBJECT'
TABLES
query_string = query_table
html = html_table
mime = pic_data
CHANGING
return_code = return_code
content_type = content_type
content_length = content_length
EXCEPTIONS
object_not_found = 1
parameter_not_found = 2
OTHERS = 3.
IF sy-subrc 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CALL FUNCTION 'DP_CREATE_URL'
EXPORTING
type = 'image'
subtype = cndp_sap_tab_unknown
size = pic_size
lifetime = cndp_lifetime_transaction
TABLES
data = pic_data
CHANGING
url = url
EXCEPTIONS
OTHERS = 1.
ENDIF.
CALL METHOD picture_control_1->load_picture_from_url
EXPORTING
url = url.
FORMAT HOTSPOT OFF.
ENDFORM.
Similar Messages
-
Dear Experts
My problem is when i am Putting Picture in Selection Screen I was able to change its width but not its Height,can anyone tell me How to Change its Height..
Thanks in Advance
SomeshHi
check this one
REPORT y_pic_show .
DATA:
docking TYPE REF TO cl_gui_docking_container,
picture_control_1 TYPE REF TO cl_gui_picture,
url(256) TYPE c .
PARAMETERS: p_dummy TYPE c .
AT SELECTION-SCREEN OUTPUT.
PERFORM show_pic.
START-OF-SELECTION.
*& Form show_pic
FORM show_pic.
DATA: repid LIKE sy-repid.
DATA: file_name LIKE sapb-sapfiles,
file_type LIKE bdn_con-mimetype.
repid = sy-repid.
IF docking IS INITIAL .
CREATE OBJECT docking
EXPORTING
repid = repid
dynnr = sy-dynnr
side = cl_gui_docking_container=>dock_at_right
extension = '200'
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5.
CREATE OBJECT picture_control_1 EXPORTING parent = docking.
CHECK sy-subrc = 0.
CALL METHOD picture_control_1->set_3d_border
EXPORTING
border = 0.
CALL FUNCTION 'DP_PUBLISH_WWW_URL'
EXPORTING
objid = 'HTMLCNTL_TESTHTM2_SAP_AG'
lifetime = 'T'
IMPORTING
url = url
EXCEPTIONS
OTHERS = 1.
Load the picture by using the url generated by the data provider.
IF sy-subrc = 0.
CALL METHOD picture_control_1->load_picture_from_url_async
EXPORTING
url = url.
ENDIF.
ENDIF .
ENDFORM. "show_pic
More on controls demo at transaction DWDM
reward points to all helpful answers
kiran.M -
Showing Picture At Selection screen.
Hi,
I want to show Picture from my PC hard drive at selection screen of abap program ( SAP repo. mime type i know but i want specially from my hard drive on pc ).
how it can be possible ? if possible give code.
Thanks,Hi
if you have a simple report " selection screen of abap program 1000 ".... I think it´s not possible....
but.
If you have a "handmade" dynpro 0100 > try to use a HTML Container ( its start a Internet Explorer .. ) and shows you the gif, jpeg..
But it´s easier to use a external/internal UI adress ( Webspace ) for the picture, as the dektop space fg
Best reg Robert -
How to insert a standard selection screen on moduled program?
Hi All,
Selection screen can be easily done in classic report by just simply invoking the event "SELECTION-SCREEN"
SELECTION-SCREEN BEGIN OF ...
SELECT-OPTIONS ...
PARAMETERS ...
In the case of moduled program, there will be a PBO and PAI, I have a requirement on my 2nd screen where I need to have a selection screen, but the SELECTION-SCREEN event is not applicable for NOT TYPE 1(Executable) Program.
My Dialog Program Flow:
Main Screen -> Display Screen (should be SELECTION SCREEN) -> Output (3rd screen)
What's the best alternative solution on this scenario?
Thanks.Hi All,
I layout and detailed my question, please see my scenario below:
screen 9000
MODULE user_command_9000 INPUT.
CASE ok_code.
WHEN 'CREATE'.
CALL SCREEN 9001.
WHEN 'DISPLAY'.
"SHOULD CALL A SELECTION SCREEN HERE
"AFTER THE SELECTION SCREEN, IS ANOTHER SCREEN FOR OUTPUT
ENDCASE.
TOP include
SELECTION-SCREEN BEGIN OF SCREEN 9003 AS SUBSCREEN.
PARAMETERS P_PLANT TYPE T001W-WERKS.
SELECT-OPTIONS: S_MATNR FOR MARA-MATNR,
S_LICHA FOR MCHA-LICHA,
S_LIFNR FOR LFA1-LIFNR.
SELECTION-SCREEN END OF SCREEN 9003.
Questions:
1. on the PAI of my main screen 9001, how can I call the SUBSCREEN I created using CALL SUBSCREEN?
the code:
CALL SUBSCREEN 9001 INCLUDING 'PROG_NAME' '9002',
is not working / syntax error.
2. Should I call it like this?
WHEN 'DISPLAY'.
CALL SCREEN 9002.
Screen 9002 PBO
CALL SUBSCREEN 9001INCLUDING 'PROG_NAME' 9002',
is not working / syntax error.
Thanks all.
Edited by: Jaime Cabanban on Dec 2, 2009 5:29 PM -
Picture in selection screen (saved in clustertable) how to load?
Hi everybody,
we got an ABAP on wich a picture should be displayed.
As we want wo have the picture in a transport ( to dispatch the ABAP on several other SAP systems ), we decided to store it in a cluster table:
This is the way we store it:
CALL FUNCTION 'WS_UPLOAD'
EXPORTING
* CODEPAGE = ' '
filename = file
filetype = 'BIN'
TABLES
data_tab = pict_tab.
EXPORT pict_tab = pict_tab TO DATABASE indx(hk) ID id.
When I now want to display the picture I (hopefully) can use:
IMPORT pict_tab = pict_tab FROM DATABASE indx(hk) ID id.
My question is: How can I convert pict_tab to an appropriate format so that it fits for the class cl_gui_picture
Thanks Regards
Mariounfortunatelly no answer :-(
-
How to attach a logo to a selection screen?
I needed to show the logo on the selection screen of a report.
So I went through several postings on this topic, created and uploaded the logo via OAER against the PICTURES object.
Per the posting, it tells to pass the value C:\logo.gif' as the url
I did so - but the logo does not appear on the screen.
So I went thorugh some demo programs - the demo programs are looking for entries in wwwparams table and are hard coding the object id while fetching these entries.
I looked for my entry in the wwwparams table, but nothing got updated into this.
Let me know if I am missing anything..
Thanks,
VenHi,
Please check this thread..
Picture in selection screen
THanks
Naren -
Creating F4 help with customized values in selection screen
Hi Dear friends
In my report i have two input flds at selection screen i.e. sales order no and date description.Now based on sales order no the F4 help in the fld date description should change dynamically.eg. if there are two sales document number 001 and 002 and the corresponding date description for 001 are 123 and 234 and for 002 are 987 and 876 .Then if i select 001 the F4 help in date description should contain 123,234 and for 002 it should contain 987,876 before pressing the execute button.How to achieve this. Plz help me. i tried to use AT-SELECTION SCREEN ON VALUE REQUEST event but its not giving any out put as in the SELECT query i putted a WHERE condition where sales document of the database table equals to the sales order inserted in the selection screen. But when i debugg the input sales order parameter shows blank.Try this way
REPORT ZVENKAT_F4_FOR_PARAMETERS MESSAGE-ID zmsg .
TYPES:
BEGIN OF t_t001w,
werks TYPE t001w-werks,
name1 TYPE t001w-name1,
END OF t_t001w,
t_return_tab TYPE ddshretval.
DATA:
w_t001w TYPE t_t001w,
w_return_tab TYPE t_return_tab.
DATA:
i_t001w TYPE STANDARD TABLE OF t_t001w,
i_return_tab TYPE STANDARD TABLE OF t_return_tab.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME.
PARAMETERS :p_werks TYPE t001w-werks,
p_name1 TYPE t001w-name1.
SELECTION-SCREEN END OF BLOCK b1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_werks.
PERFORM f4_help_for_palant.
*& Form f4_help_for_palant
FORM f4_help_for_palant.
DATA:
w_dynpfields TYPE dynpread,
i_dynpfields LIKE STANDARD TABLE OF dynpread.
IF i_t001w[] IS INITIAL.
SELECT werks name1
FROM t001w
INTO TABLE i_t001w.
ENDIF.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'WERKS'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'P_WERKS'
value_org = 'S'
TABLES
value_tab = i_t001w
return_tab = i_return_tab.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE i_return_tab INTO w_return_tab INDEX 1.
p_werks = w_return_tab-fieldval.
READ TABLE i_t001w INTO w_t001w WITH KEY werks = p_werks.
IF sy-subrc = 0.
w_dynpfields-fieldname = 'P_NAME1'.
w_dynpfields-fieldvalue = w_t001w-name1.
APPEND w_dynpfields TO i_dynpfields.
CLEAR w_dynpfields.
CALL FUNCTION 'DYNP_VALUES_UPDATE'
EXPORTING
dyname = sy-repid
dynumb = sy-dynnr
TABLES
dynpfields = i_dynpfields.
ENDIF.
ENDFORM. " f4_help_for_palant
Thanks
Venkat.O -
Dynamic program on selection screen
hi friends i want to add one insert button on selection screen and when someone click that insert button a new parameter field should gets add on the screen.
Hi,
Chk this code.But here i took radio buttons instead of pushbuttons.Hope it will help you out.
*& Report ZHAR_DYN_SELSCR.
*& This program demonstrates how easy it is to set selection screen
*& element properties dynamically
*& The program uses 3 radio buttons to set the display and input
*& properties of selection screen fields dynamically
*& URL: http://allaboutsap.blogspot.com
REPORT ZHAR_DYN_SELSCR.
DATABASE TABLES
tables : mara.
SELECTION SCREEN
selection-screen begin of block b1 with frame.
*--- Radio buttons to set properties
PARAMETERS:
rad1 RADIOBUTTON GROUP rad default 'X' USER-COMMAND radio,
rad2 RADIOBUTTON GROUP rad,
rad3 RADIOBUTTON GROUP rad.
*--- Selection Screen fields
SELECT-OPTIONS:
s_matnr FOR mara-matnr MODIF ID MI1,
s_mtart FOR mara-mtart MODIF ID MI1,
s_mbrsh FOR mara-mbrsh MODIF ID MI2,
s_matkl FOR mara-matkl MODIF ID MI2.
selection-screen end of block b1.
AT SELECTION SCREEN
at selection-screen output.
loop at screen.
*--- If Radio Button 1 is checked
IF rad1 = 'X'.
IF screen-group1 = 'MI2'.
*--- Fields with MODIF ID MI2 disappear from the screen
screen-input = 0.
screen-invisible = 1.
ENDIF.
*--- If Radio Button 2 is checked
ELSEIF rad2 = 'X'.
IF screen-group1 = 'MI1'.
*--- Fields with MODIF ID MI1 are input-disabled
screen-input = 0.
ENDIF.
*--- If Radio Button 3 is checked
ELSEIF rad3 = 'X'.
IF screen-group1 = 'MI1' or screen-group1 = 'MI2'.
*--- All fields will appear input-enabled
screen-input = 1.
ENDIF.
ENDIF.
*--- MODIFY SCREEN mandatory addition to apply changes to the screen
Modify screen.
endloop.
Reward if helpful.
Regards,
Harini.S -
PHOTO UPLOAD in selection screen
Hi expert ,
I want to know can with fixed picture with SELECTION SCREEN ??. I means when i scroll the screen it must be scroll with it.Hi,
Look i write one code to generate one page in that page there is many selection screen and screen blocks. Now i want to fixed one picture with particular selection screen block so that when i scrolling picture up and down picture must be scroll with it. -
Hello Gurus ,
I want to insert data from selection screen into my ztable , I have activated save button in menu bar , with function text SAVE and function type , E , S , null , H , P all I have tesated , but it is not working , with case sy-ucomm , when 'SAVE' .
In same way Print is working but not save .I am not getting the prob .
Is there any problem , plz help me , I m in hurry .
I am waiting for all of your valuable reply .
Regards,
Joy .Hi Joy,
Check out the below related threads for placing the push buttons ... Frame logic accordingly as per your requirement ..
push button in selecion screen
Push button on selection screen
push button on selection screen\
PUSH Button in Selection Screen -
When inserting pictures in a new mail message using the " photo browser" button I can view and select photos but the " choose " button is gone. What have I done wrong?
Hi Liz,
Sorry to hear you are having a similar problem. Last night I went to the tool bar at the top of iphoto, clicked on "File", then clicked "Browse Backups" in the drop down menu. I have an external hard drive that is set up to Time Machine. The Browse Backups opened the iphoto pages in the Time Machine. I selected a date one day ahead of the day I performed the now infamous update, and it showed my iphoto library as it had existed that day. I then clicked "Restore Library" at the bottom right corner of the Time Machine screen. Roughly 2 hours later my iphoto was back to normal. When I opened iphoto there was a message saying I need to upgrade my program to be compatible with the new version of iphoto(version 9.2.1). I clicked "Upgrade" and within seconds it had done whatever upgrading it needed to do.
The only glitch in the restoration was that it restored the library as it appeared last week, so I no longer had photos I had imported this past weekend. I simply went back to the Browse Backups in the drop down menu, when Time Machine opened I selected the page showing my pictures from this weekend and again said to Restore Library. Roughly 45 minutes later the library was restored including the most recent photos.
I am now a happy camper.
I don't know if any of this will be of help to you because your email says you are having trouble with photos imported after the upgrade was performed. Have you had any pop up notices when you first open iphoto, that tell you you need an upgrade to be compatible with the new iphoto? If so have you clicked "upgrade"?
Good luck Liz, if you have Time Machine running as a back up to your library, maybe you wil be able to get help there, by following my instructions above. Otherwise, good luck with your investigations. I'd be interested in hearing how you make out.
Karen -
Show Picture/logo on Selection Screen from OAER
HI everybody,
I uploaded a LOGO via TA OAER.
It works fine, when I Use call function 'REUSE_ALV_GRID_DISPLAY'
But now I want wot display the logo on the selection screen using the picture_control ( TYPE REF TO cl_gui_picture)
see:
ABAP - Display LOGO On Selection Screen.</title><title>Learn ABAP Programming With Examples And Sample Progr…
Does anybody know how to read the picture uploaded in OAER for using it in the picture_control ( TYPE REF TO cl_gui_picture?
Thanks
Regards
MarioThis is possible. please try following code:
PARAMETERS:c1 TYPE vbak-vbeln.
AT SELECTION-SCREEN OUTPUT.
PERFORM show_picture.
**& Form show_picture
FORM show_picture.
DATA picture_control_1 TYPE REF TO cl_gui_picture.
DATA :
docking TYPE REF TO cl_gui_custom_container,
logical_system LIKE bapibds01-log_system,
v_class LIKE bapibds01-classname,
v_type LIKE bapibds01-classtype,
v_client LIKE bapibds01-client,
v_objkey LIKE bapibds01-objkey,
url_lifetime LIKE bapibds01-uri_life,
standard_url_only LIKE sy-datar,
data_provider_url_only LIKE sy-datar,
web_applic_server_url_only LIKE sy-datar,
url_used_at TYPE sdok_fburl,
URIS TYPE TABLE OF BAPIURI WITH HEADER LINE,
url LIKE uris-uri.
v_objkey = 'FITP_SMILE'.
v_class = 'PICTURES'.
v_type = 'OT'.
v_client = sy-mandt.
CALL FUNCTION 'BDS_BUSINESSDOCUMENT_GET_URL'
EXPORTING
classname = v_class
classtype = v_type
client = v_client
object_key = v_objkey
TABLES
uris = uris.
* Find image
LOOP AT uris.
SEARCH uris-uri FOR 'smile.gif'.
IF sy-subrc = 0.
url = uris-uri.
EXIT.
ENDIF.
ENDLOOP.
BREAK-POINT.
CREATE OBJECT picture_control_1
EXPORTING
parent = docking.
CHECK sy-subrc = 0.
CALL METHOD picture_control_1->set_3d_border
EXPORTING
border = 5.
CALL METHOD picture_control_1->set_display_mode
EXPORTING
display_mode = cl_gui_picture=>display_mode_stretch.
CALL METHOD picture_control_1->set_position
EXPORTING
height = 55
left = 750
top = 08
width = 350.
CALL METHOD picture_control_1->load_picture_from_url
EXPORTING
url = url.
ENDFORM.
Regards -
Related to Displaying picture on the selection screen
Hi ,
I had a requirement where i had to display a picture on the selection screen, so i used the methods set_position and load_picture_from_url of the class cl_gui_picture to archive this, but now my selection screen has extended to more than one page because of this if i scroll down on the selection screen the picture is not scrolling it is remaining static to the screen ( i.e. if i place it (10, 10) after scrolling also it is still remaining at (10 , 10) with respect to the new screen) is there any way i can scoll the picture also i.e. it also moves up along with the screen?There could be one option : create one screen and load your picture on that screen.
Within your selection screen, call the screen created above. -
Selecting multiple image files on the 'insert picture' menu in word
Hi there,
I am trying to insert multiple pictures at once into a word document, on office for mac 2011.
I am using the 'insert picture' option from the toolbar. Shift-click doesn't work like on a PC, and i have tried a variety of button combinations that don't seem to have any effect! Is there any way around this so I don't have to insert picture files into a word document one at a time?
Thanks!You are right, it does not work. Here is a workaround by doing an intermediate stopover in TextExit (it's in your Dock and/or in your Applications folder):
In the Finder, select your multiple image files
Right-click (or control-click) and select "Copy # items"
Go to TextEdit and paste
Do Select All (Command A) followed by Copy (Command C)
Go back to Word and paste your heart out -
Inserting Selection-screen above the Field-groups created.
Hi guys,
I am having problems on how to display my selection screen before the field-groups declared. How can I insert my selection-screen above those field-groups? Do i need to create a new field group for my selection-screen and how? thanks in advance! the sample code is below this message.
regards,
Mike
<b>I.E.:</b>
FIELD-GROUPS: header, posten.
selection-screen begin of block BOMREP WITH FRAME TITLE TEXT-429.
PARAMETERS: rb_bhder RADIOBUTTON GROUP g1 DEFAULT 'X',
rb_bflvl RADIOBUTTON GROUP g1,
rb_dsply RADIOBUTTON GROUP g1,
rb_ndlpy RADIOBUTTON GROUP g1,
rb_alvl RADIOBUTTON GROUP g1.
selection-screen end of block BOMREP.>
Akashdeep Basu wrote:
> Hi,
> I am using LDB : PNP in my report. I want to add a block on the selection screen ABOVE the standard LDB screen.
>
> Plz help....
> Sample code appreciated.....
>
> Thanks,
> Akash
NOT possible. you can only append to the Std selection-screen. One option is to hide it altogether, so the user sees only the custom block...
~Suresh
Maybe you are looking for
-
Hi experts! I have deployed this files to get MDM PI Adapter: MDMCONNECTOR08_0-20008055.SCA Connector MDMJ71008_1-10006189.SCA JAVA API MDMADAPTER08_0-10005238.SCA PI ADAPTER My PI version is 7.0 SP19. My MDM
-
Time Series Line Chart - Monthly Sales - Make $0 or "No Sales" show up - not skipped
Post Author: kevinday17 CA Forum: Charts and Graphs I have been messing with my chart for a while and I guess I'll just ask for help since I can't figure it out. All I am trying to do is chart out monthly sales dollars by customer. Simple enough...
-
USERNAME, PASSWORD OF ORACLE9i SQL PLUS UNKNOWN
I installed Oracle 9i Lite Edition. The SQL Plus installed with it is not working with some default username, passwords like scott, system and internal. There wasn't a tool in the installation that configured a username/password. Plz help As I am una
-
Dear SAP friends, Does anybody knows an easy way to find function codes ( those of type ui_func) of standard ALV grid toolbar? Searching this forum I learned that you can do se11 and read table RSMPTEXTS for program SAPLSVLV_FULLSCREEN or just se41 f
-
Film Editors, help! FCE/HDV/FCP transfer issues.
I am using FCE 3.51. I want to edit HDV footage, digitized on a system with FCP 6.03. My computer plays the audio on the .mov files but I cannot view the video, there is no video. Can my FCE digitize HDV footage off a SONY HVR-7Z1U? I hope I worded t