After selection screen
hai,
thanks for giving me reply regarding selection screen for listing out tables using vrm but i need to select that table and enter into se16 transaction where the table name should appear in se16.
can anyone plzzzzz post this very urgent.
Thank u.
1. use SET parameter for 'DTB' value 'table name selected'
2.call transaction 'SE16' .
Rgds,
Similar Messages
-
Problem after selection screen -reg
Hi all
My program is not getting executed after giving the selection screen options.
can anybody suggest me what could be the problem was.
Here is my script.
REPORT ZVS_SELECT_FLIGHT .
tables: SFLIGHT.
TYPES: BEGIN OF TY_SFLIGHT,
CARRID LIKE SFLIGHT-CARRID,
CONNID LIKE SFLIGHT-CONNID,
FLDATE LIKE SFLIGHT-FLDATE,
PRICE LIKE SFLIGHT-PRICE,
CURRENCY LIKE SFLIGHT-CURRENCY,
PLANETYPE LIKE SFLIGHT-PLANETYPE,
SEATSMAX LIKE SFLIGHT-SEATSMAX,
SEATSOCC LIKE SFLIGHT-SEATSOCC,
END OF TY_SFLIGHT.
DATA: IT_SFLIGHT TYPE TY_SFLIGHT occurs 1,
WA_SFLIGHT TYPE TY_SFLIGHT.
SELECTION-SCREEN BEGIN OF BLOCK B1 with frame title text-001.
select-options so_carid for sflight-carrid no-extension no intervals
obligatory.
SELECTION-SCREEN END OF BLOCK B1.
loop at it_sflight into wa_sflight.
select * from sflight into CORRESPONDING FIELDS OF wa_SFLIGHT where carrid = so_carid.
append wa_sflight to it_sflight.
endselect.
endloop.
LOOP AT IT_SFLIGHT into WA_SFLIGHT .
write: / wa_sflight-carrid,
wa_sflight-connid,
wa_sflight-fldate,
wa_sflight-price,
wa_sflight-currency,
wa_sflight-planetype,
wa_sflight-seatsmax,
wa_sflight-seatsocc.
endloop.
Thanks in adv
sateeshhi,
there is a mistake in your progrm check the code below.
REPORT ZVS_SELECT_FLIGHT .
tables: SFLIGHT.
TYPES: BEGIN OF TY_SFLIGHT,
CARRID LIKE SFLIGHT-CARRID,
CONNID LIKE SFLIGHT-CONNID,
FLDATE LIKE SFLIGHT-FLDATE,
PRICE LIKE SFLIGHT-PRICE,
CURRENCY LIKE SFLIGHT-CURRENCY,
PLANETYPE LIKE SFLIGHT-PLANETYPE,
SEATSMAX LIKE SFLIGHT-SEATSMAX,
SEATSOCC LIKE SFLIGHT-SEATSOCC,
END OF TY_SFLIGHT.
DATA: IT_SFLIGHT TYPE TY_SFLIGHT occurs 1,
WA_SFLIGHT TYPE TY_SFLIGHT.
SELECTION-SCREEN BEGIN OF BLOCK B1 with frame title text-001.
select-options so_carid for sflight-carrid no-extension no intervals
obligatory.
SELECTION-SCREEN END OF BLOCK B1.
<b>loop at it_sflight into wa_sflight.</b> <b>"remove this</b>
select * from sflight into CORRESPONDING FIELDS OF wa_SFLIGHT where carrid <b>in</b> so_carid.
append wa_sflight to it_sflight.
endselect.
<b>endloop.</b><b> "remove this</b>
LOOP AT IT_SFLIGHT into WA_SFLIGHT .
write: / wa_sflight-carrid,
wa_sflight-connid,
wa_sflight-fldate,
wa_sflight-price,
wa_sflight-currency,
wa_sflight-planetype,
wa_sflight-seatsmax,
wa_sflight-seatsocc.
endloop.
regards,
Navneeth K.
Message was edited by:
Navneeth Bothra -
AT SELECTION-SCREEN OUTPUT not working!
Hi,
I am useing the statement AT SELECTION-SCREEN OUTPUT to disable some input fields based on a check box(PR_FILE).however when I execute the program the changes on the screen are not reflected!I have written the AT SELECTION-SCREEN OUTPUT stmt immediately after SELECTION-SCREEN stmt .
Defination for the screen elements is as follows:
SELECT-OPTIONS s_plants FOR ls_selected_plant-plant
NO INTERVALS.
SELECTION-SCREEN BEGIN OF BLOCK filesel WITH FRAME TITLE text-012.
PARAMETERS pr_file TYPE xfeld .
PARAMETER : pr_path LIKE rlgrap-filename .
SELECTION-SCREEN END OF BLOCK filesel.
AT SELECTION-SCREEN OUTPUT.
IF pr_file = 'X'.
LOOP AT SCREEN.
IF screen-name = 's_plants'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF screen-name = 'pr_path'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Can anybody suggest what wrong i have done??You need to use the User Command for the checkbox and the Modificaiton ID (Group) for the fields.
Try like this:
TABLES: VBRP.
SELECT-OPTIONS S_PLANTS FOR VBRP-WERKS NO INTERVALS MODIF ID GP1.
SELECTION-SCREEN BEGIN OF BLOCK FILESEL WITH FRAME TITLE TEXT-012.
PARAMETERS PR_FILE TYPE XFELD USER-COMMAND USR1.
PARAMETER : PR_PATH LIKE RLGRAP-FILENAME MODIF ID GP2 .
SELECTION-SCREEN END OF BLOCK FILESEL.
AT SELECTION-SCREEN OUTPUT.
IF PR_FILE = 'X'.
LOOP AT SCREEN.
if screen-group1 = 'GP1'.
SCREEN-active = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF SCREEN-group1 = 'GP2'.
SCREEN-active = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Regards,
Naimesh Patel -
F-32 - Select list of accounts at first selection screen
Hello everybody,
Like the title says, I would like to select a list of account (and a list of CGS code) directly from the first selection screen o fF-32 transaction code.
Do you know an issue to do that?
BR
MathieuHi,
TY to help me.
But the account can be selected at selection screen but by default you can't entry no more than one.
After selection screen it is possible to select several accounts and CGS code. (on detail screen)
So I would like to select all my accounts directly at the first selection screen.
Does a standard solution exist for that?
BR -
Blank Screen after selecting a role within the new WebClient User Interface
Hi,
I have another Problem with the new UI.
I did all steps as described within the Best Practice Guide for the new Web Client (C04). I used this guide to set up our CRM 2007 System.
Unfortunately no matter what I do after selecting the appropriate role after logging on to the system I only get a blank screen and nothin else happens. Even changes to the navigation frame have no effect.
If I do not assign a business role I get at least this error. But after doing this I allways got a blank screen no matter what I change in customizing.
Does anyone have any clues where the error might lie?
Best Regards
ChristianHi Christian,
Could you please share me your experience how you resolved this issue?
We are at the clients place facing the same problem. After logging in it is asking to select business roles like salespro,marketpro....etc...but after selecting this role we are getting blank white screen in the browser with URl- http://*******.**.com:8030/sap/bc/bsp/sap/crm_ui_frame/default.htm?sap-client=150&sap-sessioncmd=open
We have followed the latest 2007 Best Practice where we have assigned the roles to user like : SAP_CRM_UIIU_FRAMEWORK
SAP_CRM_OR_ADMIN
SAP_CRM_OR_USER
BP_POWERUSER
In best practice 5.2 this role was assigned through Org Model where as in 2007 first it guides us to get the WebClient and then asking us to create Org Model.
you had mentioned that you got rectified through local server settings on OS level. Can you please help in explaining what exactly you did to rectify the DNS setting????
Any other solution most welcome
Regds...Arup -
Issue in Selection Screen of ABAP report after executing it using TCode
Hi,
I have one Z program having a selection screen for it. One selection variable is non editable for the users (has default value) whereas user can enter the value in other selection variable.
To make the first variable non editable, I have used the following code.
INITIALIZATION.
LOOP AT SCREEN.
IF screen-name = 'P_USER'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Now when I execute this program from SE38, it works fine. But when I execute it using a Tcode (assigned in SE93), the first variable also become editable for users.
How can I keep the first variable non editable even after executing the program using a Tcode?
Regards,
YogeshHi,
It seems you create a Transaction type: Dialog transaction.
Delete current transaction and create one with Transaction type: Report transaction (radio button in row 2nd)
regards, -
Back to selection screen after error
Hello ABAPers,
I have a executable program (REPORT) to do some processing (e.g. read a standard table with the parameters and select-options and save the data in a Z table).
When occurs an error (e.g. when sy-subrc <> 0 after select) and a message of type E is showed, the program show the message in a "clean" screen with title SAP. Then, after ENTER or ESC, it leaves to initial screen of SAP (SAP Easy Access).
The message of type E is triggered from a routine (FORM) called from START-OF-SELECTION event. And the program don´t write nothing in list (only return a status message if everithing is ok).
How can I force the program to back to selection screen after some error?
Thanks in advance.
Best regards,
Charles Oliveirahi,
Do the following for your requirement.
in the message give the following
start-of-selection.
Perform <routine>.
Form <routine>.
if <condition>.
message 'xxxx' type 'S' display like 'E'.
exit.
endif.
endform.
This way the control returns to selection screen even after the message is triggered.
Thanks
Sharath -
"Get Variants" button disabled after error message in AT SELECTION SCREEN
Hi,
In "AT SELECTION SCREEN" I throw an error message if certain criteria return no data.
After the error message is thrown, the button for choosing variants no longer appears to work. I click it and the variant selection box doesn't come up. It just changes the values that have been populated from red to black.
What is the code that remedies this? If an error is thrown, it should allow you to select a variant still.
Thanks,
Kevin"AT SELECTION SCREEN" is not an option here. Let me clarify.
In START-OF-SELECTION, I call another program with a SUBMIT statement. That program uses a logical database. So it makes no sense to move this to "AT SELECTION SCREEN". Even when I did that, I still couldn't solve this problem.
If the SUBMIT statement returns no data (if sy-subrc = '4') then I need to go back to the initial screen. I need to display some kind of message, of type I or E or S, I don't care.
It just needs to go back to the selection screen and VARIANTS need to WORK, and you need to be able to SAVE the variants.
For some reason, if I get no data with the SUBMIT statement, I can display a message and get back to the selection screen but variants do not work. I've tried EXIT, STOP, CALL SELECTION SCREEN 1000 (the only one in the program), END LIST-PROCESSING, etc. NOTHING WORKS! -
SAP Query selection screen issues after ECC upgrade
Hi all
We have a custom query created and assigned to a custom transaction code, which after upgrade to ECC 6.0 we find that the selection screen layout is different from what was available in 4.6C system.
All the fields required are available.
However, the sequence of the fields on the screen is different from the 4.6C after the upgrade.
Can anyone help identify the issue so that the issue can be resolved?
Thanks
Vinodh SHi N_niki
There is no resolution as such.
We had raised a Customer message with SAP and were informed that this was expected as the procedure to execute the reports was changed in ECC when compared to 4.6 (technical changes) and hence this issue shall remain for some queries wherein the old changes need to be brought back using an option in the SAP Query.
Please refer to SAP Note # 723577 which could provide a better explanation for the issue.
Hope this helps.
Thanks
Vinodh Sudhakaran -
SHD0 - Selection screen of the variant appears without changes after saving
Dear all,
I created a variant for the transaction MB11 with SHD0.
In the selection screen, I hide various fields.
When I run the variant everything is working normally.
But after saving the document, the selection screen appears again without the hidden fields.
Any ideas how to avoid, after saving, the selection screen without the hidden fields?
Thanks in advance.
CarlesHello Madhu,
Thanks for your response.
I checked the link. When I have created the transaction variant I used a similar procedure.
My issue is that, when I used the variant, I loop again on the selection screen at the end. And it doesn't have the chagnes i made.
Cordially
Carles
Edited by: carles.bostezo on Sep 5, 2011 12:40 PM -
How to write in selection screen after the select option field?
Hi
Please help me with this...
i need to write format of date after the select option field in the selection screen.
its like..
date ___________ to ___________ <b>yyyymmdd</b>
points will be awarded..
thanxUse selection-screen comment 1(31) text-005 -> this will give you format option.
See the below sysntax ,you have to use like this
Selection-screen begin of block b2 with frame title text-002.
selection-screen begin of line.
selection-screen comment 1(31) text-004.
parameter: r_1 radiobutton group rad1.
selection-screen end of line.
selection-screen begin of line.
Aging Report
selection-screen comment 1(31) text-005.
parameter: r_2 radiobutton group rad1.
selection-screen comment 40(30) text-003.
parameter: p_expir as checkbox.
selection-screen end of line.
selection-screen begin of line.
Materials with no Expiry Date
selection-screen comment 1(31) text-006.
parameter: r_3 radiobutton group rad1.
selection-screen comment 40(30) text-007.
parameter : p_bin as checkbox ."default 'X'.
selection-screen end of line.
selection-screen end of block b2.
selection-screen end of block b0. -
I have Hello screen after i slide to set up gel language options after select English , Egypt it request to connect with WI FI after connect start to activate my IPhone after that it unable to activated because the activation server is unavailable and request to connect to itunes and no activate.
4 possible causes of that message:
1] Activation server is actually down. Very rare occurrence, but it does happen.
When it does occur, down time is very short. Solution - try again.
2] Your firewall or antivirus are blocking the connection. Solution - temporarily
deactivate your firewall or antivirus until the update completes.
3] Computer being used for the activation has previously been used to jailbreak
an iOS device. Solution - use a computer that has not been used to jailbreak an
iOs device.
4] Your iPhone is jailbroken. Google may provide some direction. Be advised the jailbreak
may have made changes that will prevent the iPhone from successfully activating.
Terms of Use for this forum prohibit discussion of jailbroken iPhones. -
Selection screen display after role menu selection
Hi,
I have strange situation:
- running a query on the WEB from Query Designer 3.5 first display a selection screen and then the data - what is OK or expected
- but we created an application in WAD with just role menu - if we pick the same query, from the same role - the query is displayed without selection screen. After that the variable screen can be displayed, but we needed before the query is actually displayed (some variable are filled with user exit on selection screen, ...)
Any idea?
Thanks,
TomazTomaz,
Have you checked the webtemplate properties in WAD where you can check - force selection screen display?
Bob -
Some items of selection-screen not showing after migration to QA
Hi Folks,
I'm trying to help a colleague with something rather weird:
After migrating code-changes from our DEV- to our QA-environment (SAP_BASIS 620, SAP_APPL 470), a newly added block of the selection-screen doesn't show up. We already spent quite some time debugging and tracing in both DEV and QA but cannot really spot a difference. The new block (B2) and field (S_DATE) show up in the selection-screen internal table SCREEN and the content looks to be identical. In addition to the complete block B2 missing, the frame-title for B3 has also gone AWOL.
This is happening for a rather straighforward selection-screen definition:
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-t01.
PARAMETERS : p_eaddr LIKE somlreci1-receiver OBLIGATORY .
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-t27.
SELECT-OPTIONS :
s_date FOR hrp1001-endda NO-EXTENSION.
SELECTION-SCREEN END OF BLOCK b2.
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-t23.
PARAMETERS : p_tstrun AS CHECKBOX.
SELECTION-SCREEN END OF BLOCK b3.
During debugging I already single stepped through programs like RSDBRUNT, SAPLSVAR and RSDBSPBL but nothing jumped out at me which could explain the difference between development and QA.
Do you have an idea where (else) we could look?
Thanks much and Cheers
BaerbelHi Vikranth!
Thanks for your quick reply and suggestion which I immediately followed and - guess what? - it worked! The selection-screen now looks like it should.
As we never before had this type of issue it never occurred to us to just regenerate the program in QA - next time we'll know and first try this simple fix.
Thanks again!
Cheers
Baerbel -
Selection Screen getting refreshed after execution..
Hello All,
I have a strange problem..
My selection-screen values are getting refreshed after execution and come back to selection screen. I am using normal ALV Fm to display the values. Can some suggest a possible reason?
Many thanks,
V NairNo .. I have checked it..Selection variables are not getting refreshed.
My Code Below
REPORT yhr_icm_exception_report.
Type Pool declarations
TYPE-POOLS: slis, "For AlV
sdydo, "Dynamic Documents
icon. "For ICON
Table declarations
TABLES : yhr_icm_exp_log, "ICM Exceptions Log
yhr_icm_exp_hist. "ICM Exception History
Include Constants
INCLUDE yhr_icm_constants . "Program to hold constants
Types declarations
*-To hold return field
TYPES: BEGIN OF ty_returntab.
INCLUDE STRUCTURE ddshretval. "Interface Structure
TYPES: END OF ty_returntab.
*-To hold deletion records
TYPES : BEGIN OF ty_icm_del,
tab_name TYPE yhr_tabname, "Internal table name
objid TYPE hrobjid, "Object ID
begda TYPE begda, "Begin Date
otype TYPE otype, "Object Type
END OF ty_icm_del.
*-Message details to be displayed
TYPES : BEGIN OF ty_message,
msgnr TYPE msgno, "System message number
text TYPE yhr_icm_exp_log-msgxx, "Message Text
END OF ty_message.
*-To hold exception log
TYPES : BEGIN OF ty_icm_exp_log,
msgno TYPE msgnr, "Message number
run_id TYPE yhr_icm_erun_id, "Exception Run ID
delta_id TYPE yhr_icm_run_id, "Run ID
record_type TYPE yhr_icm_exp_type, "Record Type
otype TYPE yhr_otype, "Object Type
objid TYPE hrobjid, "Object ID
begda TYPE begda, "Begin Date
msgxx TYPE msgxx, "Message
status TYPE yhr_icm_icon, "Status
delta_relevance TYPE yhr_delta_rel, "Delta Relevance
END OF ty_icm_exp_log.
*-To hold email attachment
TYPES: BEGIN OF ty_attach,
text(500) TYPE c, "Text
END OF ty_attach.
*To hold object type & text
TYPES :BEGIN OF ty_objid_text,
objid TYPE objid, "Object ID
text TYPE emnam, "Object Text
END OF ty_objid_text.
*-To hold counter values - Exp , Del & historical
TYPES :BEGIN OF ty_count,
exp(10) TYPE c, "Exceptions
del(10) TYPE c, "Deletions
hist(10) TYPE c, "Historical Deletions
END OF ty_count.
*- To hold lock details
TYPES : BEGIN OF ty_lock,
live TYPE c, "Live Callidus Program
genr TYPE c, "Generation Program
exp TYPE c, "Exception Program
END OF ty_lock.
Range Declarations
RANGES :
gr_objid FOR hrp1001-objid, "Range for Object ID
gr_pernr FOR pa0000-pernr. "Range for Employee number
Internal Table Declarations
DATA : gt_records TYPE STANDARD TABLE OF yhr_icm_exp_report,
gt_objid_text TYPE STANDARD TABLE OF ty_objid_text,
gt_icm_exp_log TYPE STANDARD TABLE OF ty_icm_exp_log,
gt_returntab TYPE STANDARD TABLE OF ty_returntab,
gt_t777o TYPE STANDARD TABLE OF t777o,
gt_diff_tab TYPE STANDARD TABLE OF yhr_icm_diff,
gt_del_tab TYPE STANDARD TABLE OF ty_icm_del, "#EC *
gt_iattach TYPE STANDARD TABLE OF ty_attach,
gt_message TYPE STANDARD TABLE OF ty_message,
gt_fieldcat TYPE slis_t_fieldcat_alv,
gt_heading TYPE slis_t_listheader,
gt_exceptions TYPE yhr_icm_exp_list_t,
gt_events TYPE slis_t_event.
Structure Declarations
DATA : gs_objid_text TYPE ty_objid_text,
gs_icm_exp_log TYPE ty_icm_exp_log,
gs_records TYPE yhr_icm_exp_report,
gs_exceptions TYPE yhr_icm_exp_list,
gs_count TYPE ty_count,
gs_fieldcat TYPE slis_fieldcat_alv, "#EC *
gs_returntab TYPE ty_returntab,
gs_icm_exp_hist TYPE yhr_icm_exp_hist,
gs_iattach TYPE ty_attach,
gs_message TYPE ty_message, "#EC *
gs_layout TYPE slis_layout_alv,
gs_t777o TYPE t777o,
gs_lock TYPE ty_lock.
Constant declarations
CONSTANTS:
c_yes TYPE string VALUE 'YES',
c_no TYPE string VALUE 'NO',
c_true TYPE c VALUE 'X',
c_deletions TYPE c VALUE 'D',
c_delta_no TYPE c VALUE 'N',
c_delta_yes TYPE c VALUE 'Y',
c_historical TYPE c VALUE 'H',
c_a TYPE c VALUE 'A',
c_error TYPE c VALUE 'E',
c_equal(2) TYPE c VALUE 'EQ',
c_participants TYPE c VALUE 'P',
c_include TYPE c VALUE 'I',
c_position TYPE c VALUE 'S',
c_organization TYPE c VALUE 'O',
c_runlock TYPE string VALUE 'RUN_LOCK',
c_parameter TYPE string VALUE 'P',
c_selfield TYPE string VALUE 'SEL_FIELD' ,
c_type TYPE string VALUE 'TYPE',
c_topofpage TYPE string VALUE 'TOP_OF_PAGE',
c_rectype TYPE string VALUE ' S_RECTYPE',
c_objectkey TYPE string VALUE 'OBJECTKEY1',
c_icon_green TYPE string VALUE '@08@',
c_icon_red TYPE string VALUE '@0A@',
c_icon_amber TYPE string VALUE '@09@',
c_green TYPE string VALUE 'GREEN',
c_amber TYPE string VALUE 'AMBER',
c_red TYPE string VALUE 'RED',
c_tabname TYPE slis_tabname VALUE 'GT_RECORDS',
c_structname TYPE dd02l-tabname VALUE 'YHR_ICM_EXP_REPORT' ,
c_siwb_wallpaper TYPE sdydo_key VALUE 'SIWB_WALLPAPER',
c_user_command TYPE slis_formname VALUE 'F01_ALV_EVENT_USER_COMMAND',
c_genname TYPE trdir-name VALUE 'YHR_ICM_GENERATE_EXCEPTIONS',
c_expname TYPE trdir-name VALUE 'YHR_ICM_EXCEPTION_REPORT',
c_pf_status TYPE slis_formname VALUE 'SET_PF_STATUS',
c_msg_class TYPE string VALUE 'YHR_ICM'.
Global Variable Declarations
DATA: gv_email_error TYPE c,
gv_email_sent TYPE c,
gv_exit TYPE c.
Selection Screen - Block I
SELECTION-SCREEN: BEGIN OF BLOCK b3 WITH FRAME TITLE text-s07.
SELECT-OPTIONS:
*- Run ID
s_run_id FOR yhr_icm_exp_hist-run_id,
*- Exception Type
s_rectyp FOR yhr_icm_exp_log-record_type NO INTERVALS,
*- Object Type
s_otype FOR yhr_icm_exp_log-otype NO INTERVALS,
*- Object ID
s_objid FOR yhr_icm_exp_log-objid NO INTERVALS,
*- Start Date
s_begda FOR yhr_icm_exp_log-begda,
*- Message number
s_msgno FOR yhr_icm_exp_log-msgno,
*- Message Text
s_msgxx FOR yhr_icm_exp_log-msgxx.
SELECT-OPTIONS:
*- Delta Relevance
s_relv FOR yhr_icm_exp_log-delta_relevance NO INTERVALS.
PARAMETERS:
*- Long Text
p_ltext AS CHECKBOX DEFAULT ' '.
SELECTION-SCREEN: END OF BLOCK b3.
Selection Screen - Block II
SELECTION-SCREEN: BEGIN OF BLOCK b2 WITH FRAME TITLE text-s08.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(14) text-033.
*-Sucess
PARAMETERS:
p_stat_s AS CHECKBOX. "D11K917251
SELECTION-SCREEN COMMENT 24(14) text-034.
*-Warning
PARAMETERS:
p_stat_w AS CHECKBOX. "D11K917251
SELECTION-SCREEN COMMENT 48(15) text-035.
PARAMETERS:
*-Error
p_stat_e AS CHECKBOX . "D11K917251
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN: END OF BLOCK b2.
Selection Screen - Block III
SELECTION-SCREEN: BEGIN OF BLOCK b4 WITH FRAME TITLE text-s09.
*-Email Details
PARAMETERS:
p_email(128) TYPE c.
SELECTION-SCREEN: END OF BLOCK b4.
Selection Screen on value request.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_msgno-low.
PERFORM f4_message.
Selection Screen Output.
AT SELECTION-SCREEN OUTPUT.
CHECK gt_returntab[] IS NOT INITIAL.
REFRESH s_msgno.
s_msgno-option = c_equal.
s_msgno-sign = c_include.
LOOP AT gt_returntab INTO gs_returntab.
s_msgno-low = gs_returntab-fieldval.
s_msgno-high = space.
APPEND s_msgno.
ENDLOOP.
At Selection Screen for Validation
AT SELECTION-SCREEN.
CLEAR gv_email_error.
*-Validate Object Type
PERFORM validate_objecttype.
*-Validate Exception ID
PERFORM fetch_exp_header.
*-Validate Exception Type
PERFORM validate_exptype.
*-Validate Message Number
PERFORM validate_msgno.
*-Validate Message Type
PERFORM validate_msgtype.
*-Validate Delta
PERFORM validate_delta.
*-Validate Email ID
PERFORM validate_email USING p_email
CHANGING gv_email_error.
IF gv_email_error IS NOT INITIAL.
MESSAGE e000(yhr_icm) WITH text-027.
ENDIF.
Initialization
INITIALIZATION.
Initialization
PERFORM initialization.
Start Of Selection
START-OF-SELECTION.
CLEAR : gv_email_error,
gv_email_sent,
gv_exit,
gs_lock.
Try locking the main program
PERFORM lock_generation_program.
CHECK gs_lock IS INITIAL.
*-Fetch the messages stored in table
PERFORM fetch_item_records.
Read object type text.
PERFORM read_text.
Get Object Text
PERFORM get_object_text.
*-Fetch the current SAP messages
PERFORM fetch_records.
*-Update Delta Flag
PERFORM update_delta_flag.
*-Compare messages in table & in SAP
PERFORM compare_message.
If receiver is not blank, try sending out mail
PERFORM send_mail USING p_email.
End Of Selection
END-OF-SELECTION.
IF gv_exit IS NOT INITIAL.
EXIT.
ENDIF.
*-Display ALV
PERFORM display_alv.
*-Build the event table for ALV display
PERFORM build_eventtab CHANGING gt_events[].
*-Fill the layout details
PERFORM layout_build .
Release all locks
PERFORM release_locks.
*-Finally call the grid display
PERFORM display_data.
*& Form set_pf_status
text
-->RT_EXTAB text
FORM set_pf_status USING rt_extab TYPE slis_t_extab. "#EC *
Set PF Status
SET PF-STATUS 'STANDARD'.
ENDFORM. "Set_pf_status
*& Form DISPLAY_ALV
text
--> p1 text
<-- p2 text
FORM display_alv .
*- Use FM to create field catalog
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
i_program_name = sy-repid
i_internal_tabname = c_tabname
i_structure_name = c_structname
CHANGING
ct_fieldcat = gt_fieldcat
EXCEPTIONS
inconsistent_interface = 1
program_error = 1
OTHERS = 1.
IF sy-subrc = 1.
MESSAGE i000(yhr_icm) WITH text-001.
EXIT.
ENDIF.
*- Remove SEL Field Column as it is not required
DELETE gt_fieldcat WHERE fieldname = c_selfield.
*-If user chooses long text, activate icon
IF p_ltext IS INITIAL.
LOOP AT gt_fieldcat INTO gs_fieldcat WHERE fieldname = c_type.
gs_fieldcat-icon = c_true.
ENDLOOP.
ENDIF.
ENDFORM. " DISPLAY_ALV
*& Form BUILD_EVENTTAB
text
<--P_GT_EVENTS[] text
FORM build_eventtab CHANGING p_events TYPE slis_t_event.
DATA: ls_event TYPE slis_alv_event.
*-Get the list of event for alv
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = p_events.
*-Add top of page event to event list
READ TABLE p_events
WITH KEY name = slis_ev_top_of_page
INTO ls_event.
IF sy-subrc = 0.
MOVE c_topofpage TO ls_event-form.
APPEND ls_event TO p_events.
ENDIF.
ENDFORM. " BUILD_EVENTTAB
*& Form LAYOUT_BUILD
text
--> p1 text
<-- p2 text
FORM layout_build .
gs_layout-zebra = c_true.
gs_layout-colwidth_optimize = c_true.
gs_layout-detail_popup = c_true.
gs_layout-detail_initial_lines = c_true.
gs_layout-detail_titlebar = text-044.
gs_layout-box_fieldname = c_selfield.
ENDFORM. " LAYOUT_BUILD
*& Form DISPLAY_DATA
text
--> p1 text
<-- p2 text
FORM display_data .
*-Display ALV display
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_user_command = c_user_command
i_background_id = c_siwb_wallpaper
i_callback_program = sy-repid
i_callback_pf_status_set = c_pf_status
i_default = c_true
i_save = c_a
is_layout = gs_layout
it_fieldcat = gt_fieldcat
it_events = gt_events
TABLES
t_outtab = gt_records.
ENDFORM. " DISPLAY_DATA
*& Form FETCH_RECORDS
text
--> p1 text
<-- p2 text
FORM fetch_records .
REFRESH : gt_diff_tab,
gt_del_tab,
gr_pernr,
gt_exceptions.
CLEAR: gs_icm_exp_log.
*-Get Employee details
PERFORM get_person_data.
*-Get Position Details
PERFORM get_position_data.
*-Get Organization Details
PERFORM get_org_data.
*-Get Exception current SAP exception list.
PERFORM get_exception_list.
*-Add deletion records
PERFORM filter_deletions.
ENDFORM. " FETCH_RECORDS
*& Form top_of_page
text
FORM top_of_page. "#EC *
PERFORM build_comment USING gt_heading.
*-Display Use FM to display Top Of Page
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = gt_heading[].
CLEAR gt_heading.
ENDFORM. "TOP_OF_PAGE
*& Form build_comment
text
-->P_HEADING text
FORM build_comment USING p_heading TYPE slis_t_listheader.
DATA: ls_hline TYPE slis_listheader,
lv_text(120) TYPE c.
*-Display report title
ls_hline-typ = c_historical.
WRITE text-006 TO lv_text.
ls_hline-info = lv_text.
APPEND ls_hline TO p_heading.
CLEAR ls_hline.
ls_hline-typ = c_s.
*-Remove leading & trailing spaces
CONDENSE : gs_count-del, gs_count-exp, gs_count-hist.
*-If the count is space then pass 0
IF gs_count-del = space.
gs_count-del = 0.
ENDIF.
IF gs_count-exp = space.
gs_count-exp = 0.
ENDIF.
IF gs_count-hist = space.
gs_count-hist = 0.
ENDIF.
IF gs_lock IS INITIAL.
*-Display Deletion, Exception, Historical Count
CONCATENATE text-037 gs_count-del
text-032 gs_count-exp
text-039 gs_count-hist
INTO ls_hline-info SEPARATED BY space.
ELSEIF gs_lock-live IS NOT INITIAL.
ls_hline-info = text-007.
ELSEIF gs_lock-genr IS NOT INITIAL.
ls_hline-info = text-008.
ELSEIF gs_lock-exp IS NOT INITIAL.
ls_hline-info = text-009.
ENDIF.
APPEND ls_hline TO p_heading.
CLEAR ls_hline.
ENDFORM. "BUILD_COMMENT
*& Form INITIALIZATION
text
--> p1 text
<-- p2 text
FORM initialization .
Read Previous run
SELECT MAX( run_id )
INTO s_run_id-low
FROM yhr_icm_exp_hist. "#EC *
s_run_id-option = c_equal.
s_run_id-sign = c_include.
APPEND s_run_id.
s_rectyp-option = c_equal.
s_rectyp-sign = c_include.
s_rectyp-low = c_error.
APPEND s_rectyp.
s_rectyp-low = c_deletions.
APPEND s_rectyp.
PERFORM restrict_selections.
*Get the message from Message Class YHR_ICM
SELECT msgnr
text
FROM t100
INTO TABLE gt_message
WHERE arbgb = c_msg_class AND
msgnr GT '000'. "#EC *
ENDFORM. " INITIALIZATION
*& Form F4_MESSAGE
text
<--P_P_MSGNO text
FORM f4_message.
F4 Help - Display all messages
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'MSGNR'
dynpprog = sy-cprog
dynpnr = sy-dynnr
dynprofield = 'S_MSGNR'
window_title = text-045
value_org = c_s
multiple_choice = c_true
TABLES
value_tab = gt_message
return_tab = gt_returntab
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 1.
IF sy-subrc = 1.
MESSAGE i000(yhr_icm) WITH text-002.
EXIT.
ELSEIF sy-subrc = 2.
MESSAGE i000(yhr_icm) WITH text-003.
EXIT.
ENDIF.
ENDFORM. " F4_MESSAGE
*& Form VALIDATE_OBJECTTYPE
text
--> p1 text
<-- p2 text
FORM validate_objecttype .
CHECK s_otype-low IS NOT INITIAL.
CONDENSE s_otype-low.
Validate object type to check whether user has entered only S, P or O
IF s_otype-low NE c_organization AND
s_otype-low NE c_position AND
s_otype-low NE c_participants .
MESSAGE e000(yhr_icm) WITH 'Enter either S(Position), P(Person) or O(Org Unit)'(021).
ENDIF.
ENDFORM. " VALIDATE_OBJECTTYPE
*& Form VALIDATE_OBJECTTYPE
FORM f01_alv_event_user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield."#EC *
DATA : lv_answer TYPE c,
lt_fields TYPE STANDARD TABLE OF sval,
ls_fields TYPE sval.
*-Get the row user has selected in ALV list
READ TABLE gt_records INTO gs_records INDEX rs_selfield-tabindex.
CASE r_ucomm.
WHEN 'DISP'.
CASE gs_records-otype.
WHEN 'S'.
SET PARAMETER ID 'POT' FIELD gs_records-otype.
SET PARAMETER ID 'PON' FIELD gs_records-objid.
CALL TRANSACTION 'PP01_DISP' AND SKIP FIRST SCREEN.
WHEN 'P'.
SET PARAMETER ID 'PER' FIELD gs_records-objid.
CALL TRANSACTION 'PA20' AND SKIP FIRST SCREEN.
WHEN 'O'.
SET PARAMETER ID 'POT' FIELD gs_records-otype.
SET PARAMETER ID 'PON' FIELD gs_records-objid.
CALL TRANSACTION 'PP01_DISP' AND SKIP FIRST SCREEN.
ENDCASE.
WHEN 'CHNG'.
CASE gs_records-otype.
WHEN 'S'.
SET PARAMETER ID 'POT' FIELD gs_records-otype.
SET PARAMETER ID 'PON' FIELD gs_records-objid.
CALL TRANSACTION 'PP01' AND SKIP FIRST SCREEN.
WHEN 'P'.
SET PARAMETER ID 'PER' FIELD gs_records-objid.
CALL TRANSACTION 'PA30' AND SKIP FIRST SCREEN.
WHEN 'O'.
SET PARAMETER ID 'POT' FIELD gs_records-otype.
SET PARAMETER ID 'PON' FIELD gs_records-objid.
CALL TRANSACTION 'PP01' AND SKIP FIRST SCREEN.
ENDCASE.
WHEN 'EMAIL'.
*- Check whether email has already been sent
IF gv_email_sent = c_true.
*- If yes, then display pop up to confirm for mailing again
CALL FUNCTION 'POPUP_TO_CONFIRM'
EXPORTING
text_question = text-041
text_button_1 = text-042
text_button_2 = text-043
IMPORTING
answer = lv_answer
EXCEPTIONS
text_not_found = 1
OTHERS = 1.
IF sy-subrc = 1.
MESSAGE i000(yhr_icm) WITH text-004.
EXIT.
ENDIF.
*- Continue only if user has selected Yes
CHECK lv_answer = '1'.
ENDIF.
*- Add Email Field & Table
ls_fields-tabname = 'SZA5_D0700'.
ls_fields-fieldname = 'SMTP_ADDR'.
APPEND ls_fields TO lt_fields.
*- Use FM to get new Email ID
CALL FUNCTION 'POPUP_GET_VALUES'
EXPORTING
popup_title = text-s09
start_column = '5'
start_row = '5'
TABLES
fields = lt_fields
EXCEPTIONS
error_in_fields = 1
OTHERS = 1.
IF sy-subrc = 1.
MESSAGE i000(yhr_icm) WITH text-004.
EXIT.
ENDIF.
*- Get the Email user has entered
READ TABLE lt_fields INTO ls_fields INDEX 1.
*- Validate Email ID
PERFORM validate_email USING ls_fields-value
CHANGING gv_email_error.
*- If the flag is not initial, indicates possible error
IF gv_email_error IS NOT INITIAL.
MESSAGE i000(yhr_icm) WITH text-027.
EXIT.
ELSE.
If no error, then try ending email
PERFORM send_mail USING ls_fields-value.
ENDIF.
WHEN 'REFRESH'.
*- Fetch the current SAP messages
PERFORM fetch_records.
*- Update Delta Flag
PERFORM update_delta_flag.
*- Compare messages in table & in SAP
PERFORM compare_message.
*- Refresh alv which is already displayed
rs_selfield-refresh = c_true.
ENDCASE.
ENDFORM. "F01_ALV_EVENT_USER_COMMAND
*& Form RESTRICT_SELECTIONS
text
--> p1 text
<-- p2 text
FORM restrict_selections .
TYPE-POOLS sscr.
STATICS: lt_restrict TYPE sscr_restrict,
lt_opt_list TYPE sscr_opt_list,
ls_*** TYPE sscr_***.
Restrict the wage type selection so the user can only enter
values with the 'EQ' clause.
CLEAR lt_opt_list.
MOVE c_objectkey TO lt_opt_list.
MOVE c_true TO: lt_opt_list-options-eq,
lt_opt_list-options-bt,
lt_opt_list-options-cp,
lt_opt_list-options-eq,
lt_opt_list-options-ge,
lt_opt_list-options-gt,
lt_opt_list-options-le,
lt_opt_list-options-lt.
APPEND lt_opt_list TO lt_restrict-opt_list_tab.
MOVE: c_s TO ls_***-kind,
c_rectype TO ls_***-name,
c_include TO ls_***-sg_main,
space TO ls_***-sg_addy,
c_objectkey TO ls_***-op_main.
APPEND ls_*** TO lt_restrict-***_tab.
*-Restrict the values OTYPE
MOVE 'S_OTYPE' TO ls_***-name.
APPEND ls_*** TO lt_restrict-***_tab.
*-Restrict the values OBJID
MOVE 'S_OBJID' TO ls_***-name.
APPEND ls_*** TO lt_restrict-***_tab.
*-Use FM to restrict the values
CALL FUNCTION 'SELECT_OPTIONS_RESTRICT'
EXPORTING
restriction = lt_restrict.
ENDFORM. " RESTRICT_SELECTIONS
*& Form GET_PERSON_DATA
text
--> p1 text
<-- p2 text
FORM get_person_data .
DATA : lt_del_tab TYPE STANDARD TABLE OF yhr_icm_diff.
SORT gt_icm_exp_log BY msgno .
gr_pernr-sign = c_include.
gr_pernr-option = c_equal.
LOOP AT gt_icm_exp_log INTO gs_icm_exp_log WHERE otype = c_participants AND
record_type = c_error.
*- Sort the table based on msgno and collect pernr
gr_pernr-sign = c_include.
gr_pernr-option = c_equal.
gr_pernr-low = gs_icm_exp_log-objid.
APPEND gr_pernr.
CLEAR gr_pernr-low.
AT END OF msgno. "#EC *
*- For the list of Pernr having same PERNR get the current exp details
IF gs_icm_exp_log-msgno = c_msg_100.
*- Export the pernr list to memory id & import in the below FM
*- Selection of records should be based on values exported from here
EXPORT gr_pernr TO MEMORY ID 'PERNR_0001'.
Get Org Assignment 0001 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0001_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_101. "Y_HR_DIFF_PERNR_0001_ORG_DATA
ELSEIF gs_icm_exp_log-msgno = c_msg_102 .
EXPORT gr_pernr TO MEMORY ID 'PERNR_0000'.
Get Actions 0000 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0000_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_103.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0002'.
Get Personal Details 0002 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0002_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_104.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0004'.
Get Disability 0004 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0004_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_105.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0006'.
Get Addresses 0006 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0006_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_106.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0007'.
Get Planned Time 0007 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0007_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_107.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0016'.
Get Contract Element 0016 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0016_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_108.
EXPORT gr_pernr TO MEMORY ID 'PERNR_0077'.
Get Additional Personal 0077 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0077_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_109 .
EXPORT gr_pernr TO MEMORY ID 'PERNR_0105'.
Get Communications 0105 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_0105_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
refresh = space
UPDATE = space
TABLES
diff_tab = gt_diff_tab
del_tab = lt_del_tab.
ELSEIF gs_icm_exp_log-msgno = c_msg_110.
EXPORT gr_pernr TO MEMORY ID 'PERNR_2001'.
Get Absences 2001 Data
CALL FUNCTION 'Y_HR_DIFF_PERNR_2001_DATA'
EXPORTING
period_begda = gs_icm_exp_hist-begda
period_endda = gs_icm_exp_hist-endda
Maybe you are looking for
-
Timed out error when running a report
The error is: "Request timed out because there has been no reply from the server in 600000 ms" Does anybody have any idea how to solve the issue? The following is more info on the report: Report has 8 subreports and data set is around 7MB size We gen
-
In one of our production DB we are experiencing huge bottlenecks due to locks. I am using OEM lock monitor to detect and identify the problematic lock. I am trying this out randomly as OEM list all the blocking locks. . Most times I am not able to an
-
Eu w/Japanese Win2K can't enter password
I haven't been able to debug this issue yet. I was just wondering if someone already knew what this might be. Maybe some kind of character set issue? A couple Japanese End Users are failing my one-way hash password protected application even though t
-
Error while starting the OA using opmnctl
HI, Am a Beginner on OAS.Am facing a error while starting the application using ./opmnctl startall. opmnctl: starting opmn and all managed processes... Failed to get IP for localhost (1) Failed to get IP for localhost (1) Failed to get IP for localho
-
Safari 4.0.3 & eBay Text Format
When working on eBay listings and on some other sites using Firefox, you are able to format your text using a bar over your text box. Much like the one I'm using now to enter this Topic. It allows you to enter text as bold, change it's color, insert