Clear download path in the selection screen
Hi All,
Im facing the problem in the selection screen.
User wants to clear the selection screen download path when they are changing the radio button one to another another radio button. this is as below
PARAMETERS::pa_werks like ekpo-wekrs,
pa_path like string.
PARAMETERS:rb1 RADIOBUTTON GROUP g01 USER-COMMAND radio,
rb2 RADIOBUTTON GROUP g01,
rb3 RADIOBUTTON GROUP g01.
ex:first default is rb1 radio button,so they will select the download path based on F4 help. then they will choose rb2,now the download path has to clear. cause they want choose F4 according to second radio button RB2.
Thank you very much.
Anu.
Hi Anitha,
Please try this code.
PARAMETERS: P_FNAME LIKE RLGRAP-FILENAME.
PARAMETERS:RB1 RADIOBUTTON GROUP G01 USER-COMMAND RADIO,
RB2 RADIOBUTTON GROUP G01,
RB3 RADIOBUTTON GROUP G01.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF RB1 = 'X'.
CLEAR P_FNAME.
ELSEIF RB2 = 'X'.
CLEAR P_FNAME.
ELSEIF RB3 = 'X'.
CLEAR P_FNAME.
ENDIF.
ENDLOOP.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FNAME.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
PROGRAM_NAME = SY-REPID
DYNPRO_NUMBER = SY-DYNNR
FIELD_NAME = 'PATH'
IMPORTING
FILE_NAME = P_FNAME.
Similar Messages
-
Physical file path on the selection screen from AL11 Tcode
Hi All,
Please let me know some body how do we give only physical file path(only directory not the file names) on the selection screen?I need to see when I press F4 only the physical file directories of the application server.
Thanks in advance.
MaheshHi,
This FM will be helpful.....
F4_dxfilename_toprecursion
CALL FUNCTION 'F4_DXFILENAME_TOPRECURSION'
* EXPORTING
* I_LOCATION_FLAG = ' '
* I_SERVER = '?'
* I_PATH =
* FILEMASK = '*.*'
* FILEOPERATION = 'R'
* IMPORTING
* O_LOCATION_FLAG =
* O_SERVER =
* O_PATH =
* ABEND_FLAG =
* EXCEPTIONS
* RFC_ERROR = 1
* ERROR_WITH_GUI = 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.
Regards,
Mdi.Deeba Najam. -
How to give dynamic file path in the selection screen
Hi All,
How to give dynamic file path f4 functionality to user on the selection so that he can browse for the path in the presentation serve? I believe there is one fun module is there for this purpose I am not getting that
Please help me in this regard.
Thanks&Regards
MaheshHI,
check this program.
<b>report ZWA_TEST2.
PARAMETERS: a(100) default 'PRESS F4'.
data: filet type table of FILE_TABLE.
data: wa type file_table.
data: count type i.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR a.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
CHANGING
FILE_TABLE = filet
RC = count .
loop at filet into wa.
a = wa-FILENAME.
endloop.</b>
Regards,
HRA -
Clearing only a few fields in the selection-screen
Hi Folks,
I am having the following fields in the selection screen.
werks.
matnr
quantity
filename like rlgrap-file.
First time the user enters some values and executes it and comes back to the selection-screen.At this point I want <b>only matnr and quantity</b> fields in the selection-screen to be cleared.
If I use FREE MEMORY it is clearing all the fields.I want only the above mentioned fields.I don't want to set the data in the in werks as default in the program.Kindly let me know how to achieve this.
Thanks,
K.Kiran.Hi Kiran,
You can write your code in AT-SELECTION SCREEN OUTPUT.
So when ever selection screen called you will have your variables you want cleared.
USe LOOP AT SCREEN.. there.
Regards,
Atish -
Clear the selection screen cached values
Hello BW gurus,
Is there a way to clear the contents of the selection screen(cached variable values) whenever it is refreshed?
Thanks,
madhuriHi Madhuri,
Please check this link if any use let me know
http://help.sap.com/saphelp_crm50/helpdata/en/6e/798e07b33b11d5993800508b6b8b11/frameset.htm
thanks
Ranganath -
How to get the file name dialog on the selection screen
Hi All
I have a selection screen in which there is a parameter where I need to enter file name. Instead of typing filename in the parameter I would like to give a path from presentation server ( I am downloading Data to presentation server ).
How to achive this functionality in case of a parameter on the selection screen. I need to have File open Dialog box like Windows here and then it should show the filename and it's path in this parameter after selectiong from the dialog box.
AmolHi..,
Use the function module <b>F4_FILENAME</b> or <b>WS_FILENAME_GET</b> in the event
<b>AT SELECTION-SCREEN ON VALUE REQUEST FOR P_FILE.</b>
Parameters p_file type rlgrap-filename.
AT SELECTION-SCREEN ON VALUE REQUEST EVENT
at selection-screen on value-request for p_file.
perform value_request.
*& Form value_request
This subroutine proposes the possible input values *
There are no interface parameters to be passed to this subroutine. *
form value_request.
call function 'WS_FILENAME_GET'
importing
filename = p_file
exceptions
inv_winsys = 1
no_batch = 2
selection_cancel = 3
selection_error = 4
others = 5.
check sy-subrc eq 0.
endform.
Reward all helpful answers !!
sai ramesh -
Compare the input filename in the selection screen
In the selection screen input field
there is an option of selecting the directory and file name and not the extension .
This is used to download the datas
Extension can be selected by using the option button
rtf
csv.
the user has to give only the filename and not the extension.
suppose if the user input is C:\temp\file1.rtf.
Either i should take only the filename
or i should display the message give only the filename and not the extension . its already been selected!!!!
I want to compare the input string contains .doc
how to do the comparison and to get the above results mentiond
Thanks in advanceBecause the requirment is there are two option buttion for selecting the download file format
But unknowingly if the user gives the filename along with the extension. I need to handle that error
giving some error message or information message
By comparing the last 4 letters of the filename.. either.doc or rtf or csv or watever
so how to do that
then after comparing that i should give the user a msg doc type is already selected give only the filename
I hope u understand my req -
How i can show the selection screen input field in the top of page in alv
hi ,
how i can show the selection screen input field in the top of page in alv grid output.
tell me the processHi,
excample from my program:
FORM topof_page.
DATA: l_it_header TYPE TABLE OF slis_listheader WITH HEADER LINE,
l_info LIKE l_it_header-info.
DATA: l_it_textpool TYPE TABLE OF textpool WITH HEADER LINE.
DATA: l_key LIKE l_it_textpool-key.
READ TEXTPOOL c_repid INTO l_it_textpool LANGUAGE sy-langu.
DEFINE m_selinfo.
if not &1 is initial.
clear l_it_header.
l_it_header-typ = 'S'.
l_key = '&1'.
translate l_key to upper case.
read table l_it_textpool with key key = l_key.
if sy-subrc = 0.
shift l_it_textpool-entry left deleting leading space.
l_it_header-key = l_it_textpool-entry .
endif.
loop at &1.
case &1-option.
when 'EQ'
or 'BT'
or 'CP'.
write &1-low to l_it_header-info.
when others.
write &1-low to l_it_header-info.
concatenate &1-option
l_it_header-info
into l_it_header-info
separated by space.
endcase.
if not &1-high is initial.
write &1-high to l_info left-justified.
concatenate l_it_header-info
l_info
into l_it_header-info
separated by space.
endif.
if &1-sign = 'E'.
concatenate ']'
l_it_header-info
into l_it_header-info.
endif.
append l_it_header.
clear: l_it_header-key,
l_it_header-info.
endloop.
endif.
END-OF-DEFINITION.
m_selinfo: s_trmdat,
s_trmext,
s_trmint,
s_fkdat,
s_delno,
s_vbeln,
s_deact,
s_kdmat.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = l_it_header[].
ENDFORM.
I hope, this will help you.
Regards
Nicole -
How to hide the selection screen of a Logical datebase?
Dear All,
I used the logical database PNP in one of my program by maintain the attribute 'Logical Database' of this program.
Now I want to hide all the selection screen of this PNP during the ABAP runtime environment.
Who can tell me how I can realize it?
Thank you!
Regards,
Brian LiuHi,
If you call the logical database using a function module, the selection
screen is not displayed.
To call a logical database from another program, use the function module LDB_PROCESS.
<b>Example code:</b>
TABLES SPFLI.
SELECT-OPTIONS S_CARR FOR SPFLI-CARRID.
TYPE-POOLS: RSDS, RSFS.
DATA: CALLBACK TYPE TABLE OF LDBCB,
CALLBACK_WA LIKE LINE OF CALLBACK.
DATA: SELTAB TYPE TABLE OF RSPARAMS,
SELTAB_WA LIKE LINE OF SELTAB.
DATA: TEXPR TYPE RSDS_TEXPR,
FSEL TYPE RSFS_FIELDS.
CALLBACK_WA-LDBNODE = 'SPFLI'.
CALLBACK_WA-GET = 'X'.
CALLBACK_WA-GET_LATE = 'X'.
CALLBACK_WA-CB_PROG = SY-REPID.
CALLBACK_WA-CB_FORM = 'CALLBACK_SPFLI'.
APPEND CALLBACK_WA TO CALLBACK.
CLEAR CALLBACK_WA.
CALLBACK_WA-LDBNODE = 'SFLIGHT'.
CALLBACK_WA-GET = 'X'.
CALLBACK_WA-CB_PROG = SY-REPID.
CALLBACK_WA-CB_FORM = 'CALLBACK_SFLIGHT'.
APPEND CALLBACK_WA TO CALLBACK.
SELTAB_WA-KIND = 'S'.
SELTAB_WA-SELNAME = 'CARRID'.
LOOP AT S_CARR.
MOVE-CORRESPONDING S_CARR TO SELTAB_WA.
APPEND SELTAB_WA TO SELTAB.
ENDLOOP.
CALL FUNCTION 'LDB_PROCESS'
EXPORTING
LDBNAME = 'F1S'
VARIANT = ' '
EXPRESSIONS = TEXPR
FIELD_SELECTION = FSEL
TABLES
CALLBACK = CALLBACK
SELECTIONS = SELTAB
EXCEPTIONS
LDB_NOT_REENTRANT = 1
LDB_INCORRECT = 2
LDB_ALREADY_RUNNING = 3
LDB_ERROR = 4
LDB_SELECTIONS_ERROR = 5
LDB_SELECTIONS_NOT_ACCEPTED = 6
VARIANT_NOT_EXISTENT = 7
VARIANT_OBSOLETE = 8
VARIANT_ERROR = 9
FREE_SELECTIONS_ERROR = 10
CALLBACK_NO_EVENT = 11
CALLBACK_NODE_DUPLICATE = 12
OTHERS = 13.
IF SY-SUBRC <> 0.
WRITE: 'Exception with SY-SUBRC', SY-SUBRC.
ENDIF.
FORM CALLBACK_SPFLI USING NAME TYPE LDBN-LDBNODE
WA TYPE SPFLI
EVT TYPE C
CHECK TYPE C.
CASE EVT.
WHEN 'G'.
WRITE: / WA-CARRID, WA-CONNID, WA-CITYFROM, WA-CITYTO.
ULINE.
WHEN 'L'.
ULINE.
ENDCASE.
ENDFORM.
FORM CALLBACK_SFLIGHT USING NAME TYPE LDBN-LDBNODE
WA TYPE SFLIGHT
EVT TYPE C
CHECK TYPE C.
WRITE: / WA-FLDATE, WA-SEATSOCC, WA-SEATSMAX.
ENDFORM.
Regards,
Sumit.
Message was edited by: sumit kumar
Message was edited by: sumit kumar -
How to Modify the Selection Screen in Report Painter
Hi All,
I am working on Report painter and writer,
can any body helpme how to change the selection screen i.e i want add some more select options to the exisiting roport .
how can i add more select options to the exisiting one
please let me know the Procedure and provide some relevent documents .
Thanks and Best regards.
umaHello...
In the program ...we can find the following chunk of code..
selection-screen:begin of block B1 with frame title text-001.
Parameters : ....
select-options:.....
selection-screen:end of block b1.
if we need to add any more user inputs we can write the code inside the existing
selection screen....end of block .
or create a new block ..just the block name should be different...
if we are using select options...we need to declare the table name using the key word for the field on which we are giving select options ....
Tables : BSIK.
Please see the following code:
Imagine :- we have the current selection screen..
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS: P_BUKRS LIKE BSIK-BUKRS DEFAULT SPACE.
SELECT-OPTIONS: S_LIFNR FOR BSIK-LIFNR.
SELECTION-SCREEN END OF BLOCK B1.
we need to add 2 more fields on the selection screen ..this we can do as the following
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS: P_BUKRS LIKE BSIK-BUKRS DEFAULT SPACE.
SELECT-OPTIONS: S_LIFNR FOR BSIK-LIFNR,
S_HKONT FOR BSIK-HKONT.
PARAMETER: P_DATE LIKE BSIK-BUDAT OBLIGATORY DEFAULT
SY-DATUM.
SELECTION-SCREEN END OF BLOCK B1.
OR...create a new block...
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-002.
SELECT-OPTIONS: S_HKONT FOR BSIK-HKONT.
PARAMETER: P_DATE LIKE RFPDO-ALLGSTID OBLIGATORY DEFAULT
SY-DATUM.
SELECTION-SCREEN END OF BLOCK B2.
there are many options available in selection screens..like creating check box,radio button etc..
for more info press F1 help on the Selection screen in the ABAP editor
Revert back if not clear and reward if helpful
Regards
Byju -
Parameter inactive in the selection screen of a report with logical datab.
I`m using a logical database in a report (PNP).
I need put as inactive some parameters of the selection screen. How can i do it ??? From customizing ???
ThanksHi,
Check this code..
" In screen loop You need to inactive the field.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-name CS 'PNPKOKRS' OR
screen-name CS 'PNPKOSTL' OR
screen-name CS 'PNPORGEH'.
screen-active = '0'.
screen-invisible = '1'.
MODIFY SCREEN.
CLEAR screen.
ENDIF.
ENDLOOP. -
Dynamic Selection option in the selection screen
Hi ,
I have a requirement like this ....
The user wants some fields to be default available in the selection screen. But they also want to be able to select the data based on additional fields (all the remaining fields ) which they want to see in the dynamic selection .
The basic list for selections should be limited to the fields listed in the specifications provided to me and the remaining fields should be made available through the dynamic selection option.
In the transaction FBL3N , this facility is provided.
Kindly help me with this..
thanks,
Sumit .Hi Sumit,
To include dynamic selection check this sample code.
TYPE POOLS DECLARATIONS FOR VALUE REQUEST MANAGER AND ICONS
TYPE-POOLS : vrm,
icon.
*SELECTION SCREEN FIELDS
TABLES : sscrfields.*GLOBAL DECLARATIONS
DATA : flag TYPE c,
tablename(10),
mmtable LIKE dd02l-tabname,
sdtable LIKE dd02l-tabname,
hrtable LIKE dd02l-tabname.*DECLARATIONS FOR SELECTION SCREEN STATUS
DATA it_ucomm TYPE TABLE OF sy-ucomm.***********SELECTION-SCREENS**********************
SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME.*FOR DYNAMIC DISPLAY OF MODULES
PARAMETERS : pa RADIOBUTTON GROUP rad USER-COMMAND com MODIF ID mod,
pb RADIOBUTTON GROUP rad MODIF ID rad,
pc RADIOBUTTON GROUP rad MODIF ID cad.SELECTION-SCREEN SKIP.**TO INCLUDE DYNAMIC ICONS
SELECTION-SCREEN COMMENT 2(6) text_001.*DYNAMIC LIST BOX BASED ON USER SELECTIONS
PARAMETERS one AS LISTBOX VISIBLE LENGTH 20 MODIF ID mod.
PARAMETERS two AS LISTBOX VISIBLE LENGTH 20 MODIF ID rad.
PARAMETERS three AS LISTBOX VISIBLE LENGTH 20 MODIF ID cad.SELECTION-SCREEN END OF BLOCK blk1.*DISPLAY DYNAMIC PUSHBUTTON ON APP TOOLBAR ON USER CLICKS
SELECTION-SCREEN: FUNCTION KEY 1,
FUNCTION KEY 2,
FUNCTION KEY 3.**EVENT ON SELECTION SCREEN FOR OUTPUT DISPLAY
AT SELECTION-SCREEN OUTPUT.*CLICK OF FIRST RADIO BUTTON
IF pa = 'X'.
sscrfields-functxt_01 = 'Materials Management'.
WRITE icon_plant AS ICON TO text_001.
*CODE TO GET DYNAMICS BASED ON THE SELECTED RADIO
LOOP AT SCREEN.
IF screen-group1 = 'MOD'.
screen-intensified = '1'.
screen-active = 1.
screen-display_3d = '1'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'RAD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'CAD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.*CLICK OF SECOND RADIO
IF pb = 'X'.
sscrfields-functxt_02 = 'Sales And Distribution'.
WRITE icon_ws_ship AS ICON TO text_001.
LOOP AT SCREEN.
IF screen-group1 = 'RAD'.
screen-intensified = '1'.
screen-active = 1.
screen-display_3d = '1'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'MOD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'CAD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.*CLICK OF THIRD RADIO
IF pc = 'X'.
sscrfields-functxt_03 = 'Human Resources'.
WRITE icon_new_employee AS ICON TO text_001.
LOOP AT SCREEN.
IF screen-group1 = 'RAD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'MOD'.
screen-intensified = '0'.
screen-active = 0.
screen-display_3d = '0'.
MODIFY SCREEN.
ENDIF.
IF screen-group1 = 'CAD'.
screen-intensified = '1'.
screen-active = 1.
screen-display_3d = '1'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.*CUSTOMISING THE TOOLBARS OF THE SELECTION SCREEN
*WITH F8 BUTTON DISABLED APPEND : 'PRIN' TO it_ucomm,
'SPOS' TO it_ucomm,
'ONLI' TO it_ucomm. CALL FUNCTION 'RS_SET_SELSCREEN_STATUS'
EXPORTING
p_status = sy-pfkey
TABLES
p_exclude = it_ucomm.
**EVENT ON THE SELECTION
AT SELECTION-SCREEN.* LIST BOX ONE VALUES
CASE one.
WHEN '1'.
mmtable = 'MARC'.
WHEN '2'.
mmtable = 'MARA'.
WHEN '3'.
mmtable = 'MARD'.
WHEN '4'.
mmtable = 'MARM'.
ENDCASE.* LIST BOX TWO VALUES
CASE two.
WHEN '1'.
sdtable = 'VBAK'.
WHEN '2'.
sdtable = 'VBAP'.
WHEN '3'.
sdtable = 'VBUK'.
WHEN '4'.
sdtable = 'VBUP'.
ENDCASE.* LIST BOX THREE VALUES
CASE three.
WHEN '1'.
hrtable = 'PA0001'.
WHEN '2'.
hrtable = 'PA0006'.
WHEN '3'.
hrtable = 'PA0022'.
WHEN '4'.
hrtable = 'PA0008'.
ENDCASE.*VALUES FOR CLICK OF THE PUSHBUTTON ON APP TOOLBAR
*AND ENABLING THE BUTTONS TO PERFORM F8
CASE sscrfields-ucomm.
WHEN 'FC01'.
tablename = mmtable.
sscrfields-ucomm = 'ONLI'.
WHEN 'FC02'.
tablename = sdtable.
sscrfields-ucomm = 'ONLI'.
WHEN 'FC03'.
tablename = hrtable.
sscrfields-ucomm = 'ONLI'.
ENDCASE.*INITIALIZATION EVENT
INITIALIZATION.*VALUES ASSIGNED TO DROPDOWNLISTS IN THE SUBROUTINES
PERFORM f4_value_request_pa.
PERFORM f4_value_request_pb.
PERFORM f4_value_request_pc.*START OF SELECTION EVENT
START-OF-SELECTION.*SUBROUTINE FOR OUTPUT
PERFORM output.*&----------------------------------------------------------------*
*& Form f4_value_request_PA
* text
*SUBROUTINE TO PROVIDE DROPDOWN VALUES TO LIST1
FORM f4_value_request_pa. DATA: l_name TYPE vrm_id,
li_list TYPE vrm_values,
l_value LIKE LINE OF li_list. l_value-key = '1'.
l_value-text = 'Plant Data for Material'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '2'.
l_value-text = 'General Material Data'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '3'.
l_value-text = 'Storage Location Data for Material'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '4'.
l_value-text = 'Units of Measure for Material'.
APPEND l_value TO li_list.
CLEAR l_value.
l_name = 'ONE'. CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = l_name
values = li_list
EXCEPTIONS
id_illegal_name = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.ENDFORM. " f4_value_request_tabname*&----------------------------------------------------------------*
*& Form f4_value_request_PB
* text
*SUBROUTINE TO PROVIDE DROPDOWN VALUES TO LIST2FORM f4_value_request_pb. DATA: l_name TYPE vrm_id,
li_list TYPE vrm_values,
l_value LIKE LINE OF li_list. l_value-key = '1'.
l_value-text = 'Sales Document: Header Data'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '2'.
l_value-text = 'Sales Document: Item Data'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '3'.
l_value-text = 'Sales Document:Header Status'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '4'.
l_value-text = 'Sales Document: Item Status'.
APPEND l_value TO li_list.
CLEAR l_value.
l_name = 'TWO'.
CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = l_name
values = li_list
EXCEPTIONS
id_illegal_name = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " f4_value_request_PB*&----------------------------------------------------------------*
*& Form f4_value_request_PC
* text
*SUBROUTINE TO PROVIDE DROPDOWN VALUES TO LIST3FORM f4_value_request_pc. DATA: l_name TYPE vrm_id,
li_list TYPE vrm_values,
l_value LIKE LINE OF li_list. l_value-key = '1'.
l_value-text = 'HR Master :Infotype 0001 (Org. Assignment)'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '2'.
l_value-text = 'Address Infotype 0006'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '3'.
l_value-text = 'Education Infotype 0022'.
APPEND l_value TO li_list.
CLEAR l_value. l_value-key = '4'.
l_value-text = 'Basic Pay Infotype 0008'.
APPEND l_value TO li_list.
CLEAR l_value.
l_name = 'THREE'.
CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = l_name
values = li_list
EXCEPTIONS
id_illegal_name = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " f4_value_request_PC
*& Form OUTPUT
* text
* -->P_TABLENAME text
*fINAL OUTPUT
FORM output. DATA p_table(10). p_table = tablename.*popup to display teh selected table and
*Continue button is clicked
CALL FUNCTION 'POPUP_TO_DISPLAY_TEXT'
EXPORTING
titel = 'User Selections '
textline1 = p_table
textline2 = 'is the Selected table'
start_column = 25
start_row = 6.*assigning the table value in p_table to the
* Table in SE16 transaction by explicitly calling
SET PARAMETER ID 'DTB' FIELD p_table.
CALL TRANSACTION 'SE16'.
ENDFORM. "OUTPUT
Regards,
Manoj Kumar P -
Layout default option on the selection screen
I have given a Select Layout box on the Selection screen of my ALV report. How can I pass the default layout value, already set in the report to the box on the selection screen as the default value.
DATA: RS_VARIANT LIKE DISVARIANT.
SELECTION-SCREEN : BEGIN OF BLOCK B10 WITH FRAME TITLE TEXT-024.
PARAMETERS : PA_VARI TYPE SLIS_VARI.
SELECTION-SCREEN : END OF BLOCK B10.
FORM ALV_VARIANT_F4 CHANGING P_PA_VARI.
DATA: "RS_VARIANT LIKE DISVARIANT,
NOF4 TYPE C,
G_REPID TYPE SY-REPID.
MOVE SY-REPID TO G_REPID.
CLEAR NOF4.
LOOP AT SCREEN.
IF SCREEN-NAME = PA_VARI.
IF SCREEN-INPUT = 0.
NOF4 = 'X'.
ENDIF.
ENDIF.
ENDLOOP.
RS_VARIANT-REPORT = G_REPID.
RS_VARIANT-USERNAME = SY-UNAME.
CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
EXPORTING
IS_VARIANT = RS_VARIANT
I_SAVE = 'A'
IMPORTING
ES_VARIANT = RS_VARIANT
EXCEPTIONS
OTHERS = 1.
IF SY-SUBRC = 0 AND NOF4 EQ SPACE.
PA_VARI = RS_VARIANT-VARIANT.
ENDIF.
ENDFORM. " ALV_VARIANT_F4
Following code is used to get the Layout selection box on the selection screen. -
Show the drop down list of variant on the selection screen in ALV reports
Hi,
i have a alv report when i execute this display will come and then i click display layout it save as a variant on the selection screen and when i go back to selection screen and press f4 on the display variant its show the drop down list of varient.
can u send me some code for this functionality...its very urgent.
thanks!
VipinHi,
try inserting this code apropietly in you program. (1 parameter + Initialization + At-selection-screen + 2 forms)
START HERE
PARAMETERS: pa_vari TYPE disvariant-variant.
INITIALIZATION.
g_repid = sy-repid.
CLEAR e_variant.
e_variant-report = sy-cprog.
e_variant-username = sy-uname.
CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
EXPORTING
i_save = 'A'
CHANGING
cs_variant = e_variant
EXCEPTIONS
not_found = 2.
IF sy-subrc = 0.
pa_vari = e_variant-variant.
ENDIF.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR pa_vari.
PERFORM alv_variant_f4 CHANGING pa_vari.
*& Form ALV_VARIANT_F4
FORM alv_variant_f4 CHANGING pa_vari.
DATA: l_exit(1) TYPE c.
CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
EXPORTING
is_variant = e_variant
i_tabname_header = 'ANYTHING'
i_save = 'A'
IMPORTING
e_exit = l_exit
es_variant = e_variant
EXCEPTIONS
not_found = 2.
IF sy-subrc = 2.
MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
IF l_exit = space.
pa_vari = e_variant-variant.
ENDIF.
ENDIF.
ENDFORM. " ALV_VARIANT_F4
END
Hope iy helps!
Alfonso -
Field in the selection screen as a select option with two default values
Hi All,
can anybody tell me how to put field in the selection screen with two defaul values.
for ex: selection screen the Account Group KNA1-KTOKD as a select option. The defeault value should be Y001 and Y005.
please reply ASAP. Its urgent.
Thanks in advance,
MadhuHi Madhu,
Since Select options are nothing but ranges, you can use the following code to add two distinct values to the select options by default.
s_ktokd-sign = 'I'.
s_ktokd-option = 'EQ'.
s_ktokd-low = 'Y001'.
append s_ktokd.
s_ktokd-low = 'Y005'.
append s_ktokd.
clear s_ktokd.
However, if you want to mention a range like all the values between these given two values to be considered then u may use,
select-options : s_ktokd for KNA1-KTOKD default 'Y001' to 'Y005'.
or
s_ktokd-sign = 'I'.
s_ktokd-option = 'BT'.
s_ktokd-low = 'Y001'.
s_ktokd-high = 'Y005'.
append s_ktokd.
Reward if helpful.
Maybe you are looking for
-
Problem with driver initialization and associated application
I am recertifying a application suite on Solaris 10. This product works well on Solaris 8 & 9. It contains a special psuedo/streams device driver that allows applications to open a port to a daemon that manages clean up of these applications. The dae
-
I am trying to add my dad to my shared photo folder and every time he get's the invite and clicks the subscribe button it tells him the photo stream is no longer shared. Apple support says that if you get that message that the owner (me) must have re
-
I'm trying to configure the built in Windows 8 Mail app to work with my custom domain. GMail is configured where I have multiple email addresses -- both the @gmail.com address, but also with my own @example.com style domain. From the browser, everyt
-
Hi All, I am trying to create a windows application for file transfer through NFC. I have Sony RC-S380 nfc reader/writer device and my windows 8 machine is able to detect it as a proximity device. I am new to NFC and wonder if i need to create an app
-
HT4539 When using App store, no icons come on
When using the App store , no icons come up for me to download and update , why is this happening & how can I fit this?