Select multiple LOV values & display in a grid
How to implement an LOV where user can select any multiple values and these values will be displayed in a grid?
Read this hOW to use SelectManyListbox or SelectManyChoice?
Its for an older version but as Frank said it should work.
Next option is to google :-)
Timo
Similar Messages
-
How to - Select Multiple Filter Values w/o Navigation ability
Just FYI, I had a requirement to allow users to select multiple characteristic filter values. Something like a capabilities a combo box would afford us.
To do this just use a Generic Nav Block Web Item and in the Web Item configuration just uncheck the "Display Navigation Icons".
It gives them the ability to select multiple filter values without all the Drill up/down capabilities.You can use multiple filter options using the web item dropdwon box.
There is a How to document available in the BW 2.0B section for this..link below.
https://websmp206.sap-ag.de/~sapdownload/011000358700003825382001E/HOWTOMULTIPLESELECTION.DOC
Thanks. -
Select options: Restricting Value Display in Search Help Parameters
Hello friends,
I have following requirement.
I have declared one select option. On that select options I'am having different search help paremeters on which I can restrict the search help values display.
Can I specify the restriction in search help at the time of programming so that it would display only the values that follows the given restriction?
I can ofcourse do this by AT SELECTION-SCREEN ON VALUE REQUEST, however I am trying to avoid this.
How can I proceed?
Points will be rewarded generously.
Best Regards,
NavinhI
SEE THIS CODE
**************DATA TYPES DECLARATION **********************
TABLES: HRP1001, HRP1026, HRP1000,PCHDY.
TYPE-POOLS SLIS.
TYPES :BEGIN OF ST_OUTPUT,
COUNT TYPE STRING,
OBJID TYPE HRP1001-OBJID,
STEXT TYPE HRP1000-STEXT,
BEGDA TYPE HRP1000-BEGDA,
ENDDA TYPE HRP1000-ENDDA,
CANCRT TYPE T77CRT-CANCRT,
AEDTM TYPE HRP1026-AEDTM,
UNAME TYPE HRP1026-UNAME,
LSTEXT TYPE HRP1000-STEXT,
RINVT TYPE T777V-RINVT,
END OF ST_OUTPUT.
TYPES: BEGIN OF ST_HRP1000,
OBJID TYPE HRP1001-OBJID,
STEXT TYPE HRP1000-STEXT,
END OF ST_HRP1000.
TYPES : BEGIN OF ST_HRP1001,
OTYPE TYPE HRP1001-OTYPE,
OBJID TYPE HRP1001-OBJID,
RELAT type hrp1001-RELAT,
BEGDA TYPE HRP1001-BEGDA,
ENDDA TYPE HRP1001-ENDDA,
SCLAS TYPE HRP1001-SCLAS,
SOBID TYPE HRP1001-SOBID,
END OF ST_HRP1001.
TYPES : BEGIN OF ST_HRP1026,
OTYPE TYPE HRP1026-OTYPE,
OBJID TYPE HRP1001-OBJID,
AEDTM TYPE HRP1026-AEDTM,
UNAME TYPE HRP1026-UNAME,
DELET TYPE HRP1026-DELET,
CANCR TYPE HRP1026-CANCR,
END OF ST_HRP1026.
TYPES : BEGIN OF ST_REASON,
CANCR TYPE HRP1026-CANCR,
CANCRT TYPE T77CRT-CANCRT,
END OF ST_REASON.
TYPES : BEGIN OF ST_SOBID,
OTYPE TYPE HRP1001-OTYPE,
OBJID TYPE HRP1001-OBJID,
RELAT type hrp1001-OBJID,
BEGDA TYPE HRP1001-BEGDA,
ENDDA TYPE HRP1001-ENDDA,
SCLAS TYPE HRP1001-SCLAS,
SOBID TYPE HRP1001-OBJID,
END OF ST_SOBID.
TYPES : BEGIN OF ST_OBJID,
OBJID TYPE HRP1001-OBJID,
END OF ST_OBJID.
TYPES : BEGIN OF ST_LOCATION,
OTYPE TYPE HRP1001-OTYPE,
OBJID TYPE HRP1001-OBJID,
RSIGN TYPE HRP1001-RSIGN,
RELAT TYPE HRP1001-RELAT,
SCLAS TYPE HRP1001-SCLAS,
SOBID TYPE HRP1001-SOBID,
END OF ST_LOCATION.
TYPES : BEGIN OF ST_LOCATION1,
OTYPE TYPE HRP1001-OTYPE,
OBJID TYPE HRP1001-OBJID,
RSIGN TYPE HRP1001-RSIGN,
RELAT TYPE HRP1001-RELAT,
SCLAS TYPE HRP1001-SCLAS,
SOBID TYPE HRP1001-OBJID,
END OF ST_LOCATION1.
TYPES : BEGIN OF ST_LSTEXT,
OTYPE TYPE HRP1000-OTYPE,
OBJID TYPE HRP1000-OBJID,
LSTEXT TYPE HRP1000-STEXT,
END OF ST_LSTEXT.
TYPES : BEGIN OF ST_OBJID_SH,
OTYPE TYPE HRP1000-OTYPE,
OBJID TYPE HRP1000-OBJID,
END OF ST_OBJID_SH.
DATA : IT_OBJID_SH TYPE STANDARD TABLE OF ST_OBJID_SH.
DATA : WA_OBJID_SH TYPE ST_OBJID_SH.
DATA : IT_LSTEXT TYPE STANDARD TABLE OF ST_LSTEXT. "TOS STORE THE TEXT OF COURCE LOCATION
DATA : WA_LSTEXT TYPE ST_LSTEXT.
DATA : IT_LOCATION TYPE STANDARD TABLE OF ST_LOCATION. " TO STORE THE LOCATION OF COURCE
DATA : WA_LOCATION TYPE ST_LOCATION.
DATA : IT_LOCATION1 TYPE STANDARD TABLE OF ST_LOCATION1. " TO CONVERT SOBID INTO OBJID FOR COURCE LOCATION
DATA : WA_LOCATION1 TYPE ST_LOCATION1.
DATA : IT_SOBID TYPE STANDARD TABLE OF ST_SOBID. " TO CHANGE THE SOBID OF HRP1001 TO OBJID OF HRP1026
DATA : WA_SOBID TYPE ST_SOBID. " BY USING FOR ALL ENTRIES
DATA : IT_REASON TYPE STANDARD TABLE OF ST_REASON. "TO STORE T HE REASON FOR CANCELL TEXT
DATA : WA_REASON TYPE ST_REASON.
DATA : IT_OUTPUT TYPE STANDARD TABLE OF ST_OUTPUT. "OUTPUT FEILDS OF REPORT.
DATA : WA_OUTPUT TYPE ST_OUTPUT.
DATA : IT_OUTPUT_1 TYPE STANDARD TABLE OF ST_OUTPUT. " TEMP OUTPUT FEILDS OF REPORT.
DATA : WA_OUTPUT_1 TYPE ST_OUTPUT.
DATA : IT_HRP1000 TYPE STANDARD TABLE OF ST_HRP1000. "DATA FROM HRP1000 TABLE
DATA : WA_HRP1000 TYPE ST_HRP1000.
DATA : IT_HRP1001 TYPE STANDARD TABLE OF ST_HRP1001. "DATA FROM HRP1001 TABLE
DATA : WA_HRP1001 TYPE ST_HRP1001.
DATA : IT_HRP1026 TYPE STANDARD TABLE OF ST_HRP1026. "DATA FROM HRP1026 TABLE
DATA : WA_HRP1026 TYPE ST_HRP1026.
DATA : IT_OBJID TYPE STANDARD TABLE OF ST_OBJID. " TO STORE THE OBJID OF HRP1001
DATA : WA_OBJID TYPE ST_OBJID.
DATA: WS_FCAT TYPE SLIS_FIELDCAT_ALV . " FEILDCATALOG FOR ALV REPORT
DATA: IN_FCAT TYPE SLIS_T_FIELDCAT_ALV.
DATA: W_LAYOUT TYPE SLIS_LAYOUT_ALV.
DATA : LV_COUNT TYPE I. "FEILD FOR SERIAL NUMBER
***************************END OF DATA DECLARATION******************************************
************SELECTION SCREEN DESIGN************************
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
*SELECT-OPTIONS : S_OTYPE FOR HRP1001-OTYPE NO INTERVALS .
SELECT-OPTIONS : S_OBJID FOR HRP1001-OBJID NO INTERVALS .
SELECT-OPTIONS : DATE FOR SY-DATUM NO-EXTENSION OBLIGATORY.
SELECTION-SCREEN END OF BLOCK B1.
***********END OF SELECTION SCREEN DESIGN******************
*****INITIALIZATION VENT TO ASIGN DEFAULT VALUES TO OTYPE
*INITIALIZATION.
S_OTYPE-LOW = 'D'.*
S_OTYPE-SIGN = 'I'.*
S_OTYPE-OPTION = 'EQ'.*
APPEND S_OTYPE.*
CLEAR S_OTYPE.*
**************END OF EVENT INITIALIZATION******************
**********VALIDATION FOR SCREEN FIELDS*********************
AT SELECTION-SCREEN ON VALUE-REQUEST FOR S_OBJID-LOW.
IF S_OBJID IS NOT INITIAL.*
SELECT OTYPE OBJID FROM HRP1000
INTO TABLE IT_OBJID_SH
WHERE OTYPE = 'D'.
IF SY-SUBRC EQ 0.
SEARCH HELP FOR QUALIFICATION.*
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
DDIC_STRUCTURE = ' '*
RETFIELD = 'OBJID'
PVALKEY = ' '*
DYNPPROG = SY-REPID
DYNPNR = SY-DYNNR
DYNPROFIELD = 'S_OBJID'
STEPL = 0*
WINDOW_TITLE =*
VALUE = ' '*
VALUE_ORG = 'S'
MULTIPLE_CHOICE = ' '*
DISPLAY = ' '*
CALLBACK_PROGRAM = ' '*
CALLBACK_FORM = ' '*
MARK_TAB =*
IMPORTING*
USER_RESET =*
TABLES
VALUE_TAB = IT_OBJID_SH
FIELD_TAB =*
RETURN_TAB = RETURN_TAB*
DYNPFLD_MAPPING =*
EXCEPTIONS*
PARAMETER_ERROR = 1*
NO_VALUES_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.
ENDIF. -
Hello there - Before I explain my issue, I would like to point out that I have reviewed some other discussions on selecting default values for multiple selection listbox. But my issue is specific and different, and not answered by any of the discussions
I visited.
I have a multiple selection list box (say for example all countries in the world as values), and I would like to pre-select or setup multiple default values (say five countries) based on some criteria that I query from MS SQL database table.
I know we can go to Data | Default Values option to setup one or many default values for multiple selection list box. When I enter the default values manually this works. I also right click the field under the Multiple-Selection List Box group, then select
Add another Value Below and set the Default Value for this field to setup multiple default values.
However, if I reference a field (either an infopath field or a field from SQL database) I am not able to setup multiple default values. Infopath automatically selects the last field I selected for all instances and in the end I am able to see only one
default value selected instead of many. How to fix this problem? Why would infopath allow multiple default values when we enter it manually but not when we reference some fields?
Please let me know if you need more info. Appreciate your help.
Thanks!Hi redhotc,
According to your description, my understanding is that you want to set multiple default values for a multiple checkbox list in InfoPath form.
I did a test with SQL database table. I set three default values for the checkbox list by adding three values field under the group field(Data->Default values), each value field is for a default value. Then publish it to my SharePoint site, everything
was fine.Please have a try as the below link:
http://www.bizsupportonline.net/infopath2010/pre-select-items-multiple-selection-list-box-infopath-2010.htm
Note: if you are using SQL databse table, you may need to enable ‘Allow cross-domain data access for user form templates that use connection settings in a data connection file’ in CA. More information, please refer to:
http://answers.flyppdevportal.com/categories/sharepoint2010/sharepoint2010customization.aspx?ID=418b9423-a96c-4e5e-91f9-6a1b010ebb69
I hope this helps.
Thanks,
Wendy
Wendy Li
TechNet Community Support -
Select multiple groups of contiguous images in Grid view
In Windows, the following conventions should be followed when selecting images in the Library module or Filmstrip.
1. select an image by left mouse click
2. extend the contiguous selection by Shift+left mouse click on the last image in group
3. add to the selection by Ctrl+left mouse click on an image
4. add another contiguous selection by Shift+Ctrl+left mouse click on the last image in group.
In LR V1 on Windows XP Pro, only 1,2, and 3 work; but adding a second contiguous selection (point 4) does not work and behaves like point 3. More images can only be added to a selection by Ctrl+left mouse clicking each individual image (which quickly gets tiresome.)
Note that these conventions work in both Bridge CS2 and beta CS3.Second that!
Shift+Page Down to select next page down as well Ctl+Shift+End to select everything to the end of the grid would also be useful -
Select list return value displayed in another item
The subject pretty much defines it. I have 3 items on a page select list, displays as text (based on LOV), and a text box. My idea is to display a control number in the select list. When the user selects the number that they want I would like the return value to fill in the displayed as text item. Then user can then use the text box to update that information.
My question is how do I get the return value to display on the users selection?
Thanks,
DerekTry to compute that item.
Denes Kubicek -
Date field not updated when select on F4 value on editable ALV Grid
Can some one look into this to see what was wrong.
I have a report that display fields extracted from a ZTable and display on an ALV Editable Grid.
The data are displayed as read only mode for these fields:
Field A - type char20 and have a search help available.
Start Date - type dats
End Date - type dats.
Field B
Field C ...
When user select to add new record, Field A, Start Date and End Date must be editable, the rest are read only.
On field A because there is search help available, I have no problem select data on F4 pull down menu and the data is updated on the grid.
But on field start date and end date, there is F4 menu and when you pull down, it shows the calendar date. But when I select the date to change, it acts like nothing happens. I run the debug mode and found out that in function module 'F4IF_FIELD_VALUE_REQUEST', after you select the date field, I got the return code irc = 8 from line 305 of this FM.
Here is what I did.
I build field catalog similar like BCALV_EDIT04 (add table type lvc_t_styl to each extracted record to indicate which field will be editable.
In the PBO, I build field catalog and set style as enable for these fields:
CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
EXPORTING
i_structure_name = p_struct
CHANGING
ct_fieldcat = p_t_fieldcat.
LOOP AT p_t_fieldcat INTO ls_fcat.
CASE ls_fcat-fieldname.
when 'Field_A'.
ls_fcat-ref_table = 'ZTABNAME'.
ls_fcat-ref_field = 'FIELD_A'.
ls_fcat-edit = 'X'.
MODIFY p_t_fieldcat FROM ls_fcat.
when 'START_DATE' or 'END_DATE'.
ls_fcat-style = CL_GUI_ALV_GRID=>MC_STYLE_enabled.
MODIFY p_t_fieldcat FROM ls_fcat.
endcase.
Just curious, I copied program BCALV_EDIT_08 to ZBCALV_EDIT08 and make field booking date as editable to test. When I select to change booking date from F4 menu pull down, the new date is populated to the screen field. So what was wrong between my program and BCALV_EDIT_08? Thanks for your help. I am stuck on this problem for 2 days and could not figure out what was wrong.not sure why you use that FM for date filed , you just need in the field catalog make sure that are use a date field of reference , anyway check program BCALV_EDIT_01
-
Select the filter value display "No Entries Found"
Hi All,
I have a problem with the bex query. Query is built on a multiprovider.
I am using restricted key figure with constant selection checked for the characteristic that is available only in one cube.
Because of this when I right click and select Filter values on the free characteristics from the report, I get (No Entries Found)
If I remove constant selection from the key figure, report works fine.
Can someone help with a solution;
Thanks,
BijuAssuming your data is coming from only one cube...
Drag 0INFOPROV in your Filter and restrict it with your your Cube
You can find 0INFOPROV in Dimensions under Data package
Hope this helps. -
Hi everyone,
I need you help in preparing a query
So I have a table that looks like this
ID Time
1 10
1 11
2 12
2 13
1 14
3 15
3 16
And I need to get for each ID it's minimal time and and then maximal time that is less that minimal for this ID
So it would look like this
ID TimeMin TimeMax
1 10 -
2 12 11
3 15 14
Please help me with that!Solomon Yakobson wrote:
chris227 wrote:
Which one is more efficient?SORT PUSHED RANK is more efficient since it provides top n query optimization.I doubt that this is always the case, may be the difference is meaningless.
create table data as (
select length(object_name) id, rownum time
from all_objects
where rownum < 10001
select
id
, min(time) timemin
, min(lt) keep (dense_rank first order by lt nulls first) timemax
from (
select
id
, time
, lag(time) over (order by time) lt
from data
group by
id
Operation Options Object Rows Time Cost Bytes
SELECT STATEMENT 10,000 1 13 390,000
SORT GROUP BY 10,000 1 13 390,000
VIEW 10,000 1 10 390,000
WINDOW SORT 10,000 1 10 260,000
TABLE ACCESS FULL DATA 10,000 1 7 260,000
select id,
time timemin,
lt timemax
from (
select id,
time,
lag(time) over (order by time) lt,
row_number() over (partition by id order by time) rn
from data
where rn = 1
Operation Options Object Rows Time Cost Bytes Filter Predicates * Access Predicates
SELECT STATEMENT 10,000 1 13 520,000
VIEW 10,000 1 13 520,000 "RN" = 1
WINDOW SORT PUSHED RANK 10,000 1 13 260,000 ROW_NUMBER() OVER ( PARTITION BY "ID" ORDER BY "TIME")< = 1
WINDOW SORT 10,000 1 13 260,000
TABLE ACCESS FULL DATA 10,000 1 7 260,000 see also http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:122801500346829407 for a similar example.
Regards -
Getting error while selecting LOV value
Hi all,
I am getting the below error in R12 apps while selecting the lov value from list (But it is working properly in 11i apps and loacal jdeveloper.)
Error: Stale Data
The requested page contains stale data. This error could have been caused through the use of the browser's navigation buttons (the browser Back button, for example).
Cause:
The view object ProjectInformationAM.EmployeeLOVVO1 contained no record. The displayed records may have been deleted, or the current record for the view object may not have been properly initialized.
To proceed, please select the Home link at the top of the application page to return to the main menu. Then, access this page again using the application's navigation controls (menu, links, and so on) instead of using the browser's navigation controls like Back and Forward.
The lov query is select employee_number,full_name from per_all_people_f
I have tried both internal and external lov but both cases it is showing the error in R12
I have used below code in PR of create page, still no use
if(!am.getEmployeelovVO1().isPreparedForExecution())
am.getEmployeelovVO1().executeQuery();
Row row1 = am.getEmployeelovVO1().createRow();
am.getEmployeelovVO1().insertRow(row1);
row1.setNewRowState(Row.STATUS_INITIALIZED);
Except this lov all lov's working properly,
Any one help on this it is very very urgent....
ThanksHi,
I had a similar issue just now, and we fixed it in this way. But the case is probably different compared to your situation.
Situation:
- custom inquiry page
- case: manual search, so not results based or Auto Customization Criteria
- multiple search criteria fields
- separate AM for all the LOV fields
- each LOV has its own VO
- Results table on same page, but with its own VO
- each search criteria field has Lov mapping to the corresponding external Lov region
Issue: when selecting a value via the Lov and coming back into the search page, I received the stale data error.
searched lots of places and finally figured out what was wrong in my case.
Each search field had its BC4J properties set to the VO of the results table. And since we wanted to make a manual search thing, this is not good.
Removing the View Instance value and the View Attribute value in the properties of the search fields resolved the error.
Hoperfully this can help other beginners, like me, in finding a solution for the same mistakes... :)
regards
Ronny -
Multiple Single Values in Customer Exit
Hi,
Can we select multiple single values in the customer exit. I know that we can get single value or range of values with LOW, HIGH, OPTION, SIGN etc. But is it possible to do a multiple single values.
Any help would be greatly appreciated.
Thanks,
AceGanesh,
Thanks for the reply, it did give me good ide
But I do not know how many multiple values I would have. I will be picking those values based on an internal table. So do I need to do another looping.
Thanks,
Ace -
Multiple selection in DISPLAY only ALV GRID
Hi,
I would like to make the rows of the ALV Grid Display only at the same time I would like to make multiple selection possible.
Multiple selection is possible by giving EDIT = 'X' at the layout level. But then if we give EDIT = ' ' at the fieldcatalogue level or no_input = 'X' at the layout level it is still in Editable mode. Kindly help me.
ThanksHi,
Setting and getting selected rows (Columns) and read line contents
You can read which rows of the grid that has been selected, and dynamic select rows of the grid using methods get_selected_rows and set_selected_rows. There are similar methods for columns.
Note that the grid table always has the rows in the same sequence as displayed in the grid, thus you can use the index of the selected row(s) to read the information in the rows from the table. In the examples below the grid table is named gi_sflight.
Data declaration:
DATA:
Internal table for indexes of selected rows
gi_index_rows TYPE lvc_t_row,
Information about 1 row
g_selected_row LIKE lvc_s_row.
Example 1: Reading index of selected row(s) and using it to read the grid table
CALL METHOD go_grid->get_selected_rows
IMPORTING
et_index_rows = gi_index_rows.
DESCRIBE TABLE gi_index_rows LINES l_lines.
IF l_lines = 0.
CALL FUNCTION 'POPUP_TO_DISPLAY_TEXT'
EXPORTING
textline1 = 'You must choose a valid line'.
EXIT.
ENDIF.
LOOP AT gi_index_rows INTO g_selected_row.
READ TABLE gi_sflight INDEX g_selected_row-index INTO g_wa_sflight.
ENDIF.
ENDLOOP.
Example 2: Set selected row(s).
DESCRIBE TABLE gi_index_rows LINES l_lines.
IF l_lines > 0.
CALL METHOD go_grid->set_selected_rows
exporting
it_index_rows = gi_index_rows.
ENDIF.
Make an Exception field ( = Traffic lights)
There can be defined a column in the grid for display of traffic lights. This field is of type Char 1, and can contain the following values:
1 Red
2 Yellow
3 Green
The name of the traffic light field is supplied inh the gs_layout-excp_fname used by method set_table_for_first_display.
Example
TYPES: BEGIN OF st_sflight.
INCLUDE STRUCTURE zsflight.
TYPES: traffic_light TYPE c.
TYPES: END OF st_sflight.
TYPES: tt_sflight TYPE STANDARD TABLE OF st_sflight.
DATA: gi_sflight TYPE tt_sflight.
Set the exception field of the table
LOOP AT gi_sflight INTO g_wa_sflight.
IF g_wa_sflight-paymentsum < 100000.
g_wa_sflight-traffic_light = '1'.
ELSEIF g_wa_sflight-paymentsum => 100000 AND
g_wa_sflight-paymentsum < 1000000.
g_wa_sflight-traffic_light = '2'.
ELSE.
g_wa_sflight-traffic_light = '3'.
ENDIF.
MODIFY gi_sflight FROM g_wa_sflight.
ENDLOOP.
Name of the exception field (Traffic light field)
gs_layout-excp_fname = 'TRAFFIC_LIGHT'.
Grid setup for first display
CALL METHOD go_grid->set_table_for_first_display
EXPORTING i_structure_name = 'SFLIGHT'
is_layout = gs_layout
CHANGING it_outtab = gi_sflight.
Color a line
The steps for coloring a line i the grid is much the same as making a traffic light.
To color a line the structure of the table must include a Char 4 field for color properties
TYPES: BEGIN OF st_sflight.
INCLUDE STRUCTURE zsflight.
Field for line color
types: line_color(4) type c.
TYPES: END OF st_sflight.
TYPES: tt_sflight TYPE STANDARD TABLE OF st_sflight.
DATA: gi_sflight TYPE tt_sflight.
Loop trough the table to set the color properties of each line. The color properties field is
Char 4 and the characters is set as follows:
Char 1 = C = This is a color property
Char 2 = 6 = Color code (1 - 7)
Char 3 = Intensified on/of = 1 = on
Char 4 = Inverse display = 0 = of
LOOP AT gi_sflight INTO g_wa_sflight.
IF g_wa_sflight-paymentsum < 100000.
g_wa_sflight-line_color = 'C610'.
ENDIF.
MODIFY gi_sflight FROM g_wa_sflight.
ENDLOOP.
Name of the color field
gs_layout-info_fname = 'LINE_COLOR'.
Grid setup for first display
CALL METHOD go_grid->set_table_for_first_display
EXPORTING i_structure_name = 'SFLIGHT'
is_layout = gs_layout
CHANGING it_outtab = gi_sflight.
Refresh grid display
Use the grid method REFRESH_TABLE_DISPLAY
Example:
CALL METHOD go_grid->refresh_table_display.
ALV Grid Control with column and row selection
Selecting and Deselecting Rows
Use
Depending on where the ALV grid control is used, there are various methods for selecting and deselecting cells and rows:
If no pushbuttons are displayed on the left edge of the list:
You can only select one row at a time.
You can select multiple rows.
If pushbuttons are displayed on the left edge of the list:
You can select several rows or individual cells.
You can select several rows as well as several cells or individual cells.
Procedure
If no pushbuttons are displayed on the left edge of the list, you select a row by clicking an entry in the row.
If pushbuttons are displayed on the left edge of the list, you select a row by clicking the pushbutton on the relevant row.
In this case, you select the relevant cell by selecting the entry in the row.
In both cases:
To select several rows, press the Shift button and choose the cells as described above.
Adjacent rows:
Select a row, choose Shift or Control, and select the desired rows,
or
Choose Shift, and select the first and the last of the desired rows,
or
Select a row, keep the mouse button pressed, and pass over the desired rows.
Rows that are not adjacent:
Select a row, choose Control, and select the desired rows.
All rows:
You can only select all rows at once if pushbuttons are displayed on the left side of your list. To select all rows, choose .
To deselect individual rows, press the Ctrl button and click the relevant row.
Result
The selected cells have an orange background. The position of your cursor is indicated with a yellow background. -
Multiple Default Values in a Multi-Select LOV Parameter?
Hi,
I have a report in BI Publisher standalone version 10.1.3.4. The report has a list of values called org_lov. This lov is attached to a multi-selection p_org_code parameter from which it is desirable to also have multiple default values.
For example, if org_lov has the following values:
100
101
102
103
104
105
106
I would like to have 3 default values and have 100, 101,105 as the defaults if the user doesn't specifically select anything from the LOV. So far my testing has only allowed a single default value.
Here are my settings:
Data type = string
Multiple Selection = checked
Can select All = checked (all values passed)
On the Default Value field, I have tried the following:
1. 100, 101,105
2. [100, 101,105]
3. '100', '101','105'
4. (100, 101,105)
5. ['100', '101','105']
6. ('100', '101','105')
I don't need these default values highlighted in the LOV, I just need it passed correctly to the query (a data template).
Thank you in advance for any input.Hi,
Sorry for the delayed reply. I tried what you suggested but the problem is that by having the "Multiple Selection" property of the parameter unchecked, the result is that it allows the user to only have a single value passed. The user wants the option to select multiple values AND also have the multiple default values.
Thanks anyway. -
Selecting Multiple Rows from ALV GRID Display
Hi,
I am having a ALV GRID Display. I want to select multiple rows from the Output and move them to an internal table.
Please let me know how do I acheive this.
Thanks in advance,
Ishaq.Hi,
Have a look on the following code. It displays the selected rows which hv been selected in basic list.
TABLES:
spfli.
TYPE-POOLS:
slis.
DATA:
BEGIN OF t_spfli OCCURS 0,
checkbox.
INCLUDE STRUCTURE spfli.
DATA: END OF t_spfli.
DATA:
t_sspfli LIKE STANDARD TABLE OF t_spfli .
DATA:
fs_spfli LIKE LINE OF t_sspfli.
DATA:
fs_layout TYPE slis_layout_alv,
w_program TYPE sy-repid.
SELECT *
FROM spfli
INTO CORRESPONDING FIELDS OF TABLE t_spfli.
*fs_layout-info_fieldname = 'COLOR'.
fs_layout-box_fieldname = 'CHECKBOX'.
w_program = sy-repid.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = w_program
i_callback_pf_status_set = 'FLIGHT'
i_callback_user_command = 'SPFLI_INFO'
i_structure_name = 'SPFLI'
is_layout = fs_layout
TABLES
t_outtab = t_spfli
EXCEPTIONS
program_error = 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.
*& Form FLIGHT
text
-->RT_EXTAB text
FORM flight USING rt_extab TYPE slis_t_extab..
SET PF-STATUS 'FLIGHT' EXCLUDING rt_extab.
ENDFORM. "FLIGHT
*& Form SPFLI_INFO
text
-->UCOMM text
-->SELFIELD text
FORM spfli_info USING ucomm LIKE sy-ucomm
selfield TYPE slis_selfield.
selfield-refresh = 'X'.
CASE ucomm.
WHEN 'FLIGHT'.
LOOP AT t_spfli.
IF t_spfli-checkbox = 'X'.
t_spfli-checkbox = ' '.
t_spfli-color = 'C51'.
MODIFY t_spfli TRANSPORTING checkbox.
fs_spfli = t_spfli.
APPEND fs_spfli TO t_sspfli.
ENDIF.
ENDLOOP.
WHEN 'EXIT'.
LEAVE PROGRAM.
ENDCASE.
CLEAR fs_spfli.
fs_layout-info_fieldname = 'COLOR'.
fs_layout-confirmation_prompt = 'X'.
fs_layout-key_hotspot = 'X'.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = w_program
i_structure_name = 'SFLIGHT'
is_layout = fs_layout
TABLES
t_outtab = t_sspfli
EXCEPTIONS
program_error = 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.
REFRESH t_sspfli.
ENDFORM. "SPFLI_INFO
Regards,
Chandu -
Selecting multiple rows in ALV grid display
Hi,
I have an ALV grid display in my report.
My grid contains multiple rows.
I have to select multiple rows at a time, to perform some operations on the selected rows.
How can it be achieved?
Thanks,
Sandeep.Hi ,
you have to use a box fieldname in the report to be able to select multiple lines at a time :
- in your internal table declaration put the first field as 'box_fieldname' of type c1
- then in your work area for layout add, lwa_layout-box_fieldname = 'box_fieldname'
- in the perform for handling user commands, all selected lines will have an "X" in the field name 'box_fieldname'
Thanks and Regards,
Dev.
Maybe you are looking for
-
Since IOS7 update, my car stereo will not communicate with my Iphone 4
Ok, I have had Kenwood car stereos with bluetooth connection since they came out with it and I have never had a problem. Now I am so mad, I am ready to throw my phone out the window. I can plug into usb or stream music bluetooth and it plays just l
-
Read receipt in snow leopard mail...
I am relatively new to mac and mail. can anyone please help me with delivery receipts and read receipts like one can get from those awful windows applications?
-
Good evening all, This Flash Player issue is giving me fits, so I'm hoping one of you might have experienced this before. Websites visited on this tablet do not recognize Adobe Flash Player. I have installed Adobe Flash Player ver 11.5.502.135 for In
-
12" 13" or 14" notebooks that can run CS5.5 half decently?
Hello, I am buying a new laptop with the intention of doing some HD video editing. When seated at my desk I will use an external HD monitor, but I am looking for a fairly compact laptop so I can remain portable. Are there any models that are reccomen
-
Can we have more than one service method in a single servlet
can we have more than one service method in a single servlet?explain with example