ALV cells as buttons
Hello,
I'm using attribute cl_gui_alv_grid=>mc_style_button to put some cells in my ALV as buttons. I need that when the user push those buttons an event is raised. Does someone have any example of buttons in ALV cells?
Thank you and regards.
Hello,
I'm using attribute cl_gui_alv_grid=>mc_style_button to put some cells in my ALV as buttons. I need that when the user push those buttons an event is raised. Does someone have any example of buttons in ALV cells?
Thank you and regards.
Similar Messages
-
Individual cell data buttons for each app keep turning on by themselves?
I have a 4S iPhone, OS 7.0.6, and my problem is that the individual cell data buttons for each app keep turning on by themselves. I'll go in and turn them all off and the next time I look (whether in 5 min or 5 hrs) they are all turned back on again? I want to leave my cell data on so that I receive my iMessages but usually don't want everything else turned on until I get to a wifi zone. I used to be able to keep them all off until I did the last couple iOS updates. Help!
Hey there Tylyssanna,
It sounds like your cellular data options are not saving correctly. I recommend starting by turning off Cellular Data in Settings first. Then close all the running apps:
iOS: Force an app to close
http://support.apple.com/kb/ht5137
Double-click the Home button.
Swipe left or right until you have located the app you wish to close.
Swipe the app up to close it.
When you have done that and restart the phone, turn it back on, and test the issue again:
iOS: Turning off and on (restarting) and resetting
http://support.apple.com/kb/ht1430
Thank you for using Apple Support Communities.
Cheers,
Sterling -
hi ,
can one send me program for alv cell color with help of function modules
kiranHi Kiran .
<b>1.Cell Color.</b>
While Building Fieldcatalog ,there is one field called
EMPHASIZE.You have to set like this .
i_field-emphasize = 'C26'.
<b>2.ROW COLOR.</b>
Have a look at this example .
<b>a</b>.Define one variable COLOR in ur main ITAB.
<b>b</b>.Fill it .
<b>c</b>.Pass this info.
w_layout-info_fieldname = 'COLOR'.
<b>d</b>. display it .
*& Report ZGRID_COLOR *
REPORT zgrid_color .
TYPE-POOLS slis.
DATA: BEGIN OF i_pa0001 OCCURS 0,
<b> color(3) TYPE c,</b>
pernr TYPE pa0001-pernr,
subty TYPE pa0001-subty,
END OF i_pa0001.
DATA :i_field TYPE slis_t_fieldcat_alv,
w_field LIKE LINE OF i_field,
w_layout TYPE slis_layout_alv.
START-OF-SELECTION .
PERFORM get_data.
PERFORM fieldcat.
PERFORM layout_build.
PERFORM dispaly .
*& Form fieldcat
FORM fieldcat .
CLEAR :w_field,i_field[].
w_field-fieldname = 'PERNR'.
w_field-tabname = 'I_PA0001'.
w_field-seltext_m = 'PERNR'.
APPEND w_field TO i_field.
CLEAR w_field.
w_field-fieldname = 'SUBTY'.
w_field-tabname = 'I_PA0001'.
w_field-seltext_m = 'SUBTY'.
APPEND w_field TO i_field.
CLEAR w_field.
ENDFORM. " fieldcat
*& Form dispaly
FORM dispaly .
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
i_callback_program = 'ZGRID_COLOR'
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = ' '
I_GRID_TITLE =
I_GRID_SETTINGS =
<b> is_layout = w_layout</b>
it_fieldcat = i_field
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT =
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
I_SAVE = ' '
IS_VARIANT =
IT_EVENTS =
IT_EVENT_EXIT =
IS_PRINT =
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IT_ALV_GRAPHICS =
IT_HYPERLINK =
IT_ADD_FIELDCAT =
IT_EXCEPT_QINFO =
I_HTML_HEIGHT_TOP =
I_HTML_HEIGHT_END =
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
t_outtab = i_pa0001
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.
ENDFORM. " dispaly
*& Form get_data
FORM get_data .
SELECT pernr subty
FROM pa0001
INTO CORRESPONDING FIELDS OF TABLE i_pa0001
UP TO 10 ROWS.
LOOP AT i_pa0001.
IF sy-tabix GT 5.
<b> i_pa0001-color = 'C51'.</b>
MODIFY i_pa0001 INDEX sy-tabix.
ENDIF.
ENDLOOP.
ENDFORM. " get_data
*& Form layout_build
FORM layout_build .
<b> w_layout-info_fieldname = 'COLOR'.</b>
ENDFORM. " layout_build
I hope it helps u .
<b>Thanks,
Venkat.O</b> -
Set ALV Cell visibility property
Hi,
I would have 2 tables for ALV. One table consists of the data to be bound to the ALV. The other table would have the read only property(boolean) filled for each of the ALV cells.
I would want to set the property of each ALV cell using the second table. How do i do that?
Currently i am just testing it for few attributes statically using the below code.
DATA lo_nd_date_table TYPE REF TO if_wd_context_node.
DATA lo_el_date_table TYPE REF TO if_wd_context_element.
DATA: lt_ele_set TYPE wdr_context_element_set.
navigate from <CONTEXT> to <DATE_TABLE> via lead selection
lo_nd_date_table = wd_context->get_child_node( name = wd_this->wdctx_date_table ).
lt_ele_set = lo_nd_date_table->get_elements( ).
LOOP AT lt_ele_set INTO lo_el_date_table.
lo_el_date_table->set_attribute_property(
attribute_name = 'WK02' -
> Attribute Name (Column Name)
property = if_wd_context_element=>e_property-read_only
value = 'X' ).
<< Similarly for other attributes>>
ENDLOOP.
I have inserted this code at the end. Initially few other properties were set to the cells.
This seems to be not working.
Regards,
Rekha
Edited by: Rekha Gopinath on Sep 8, 2009 10:40 AMHi Lekha,
In my case, the columns represents dates. The rows represent projects. So, only those row cells are editable where the project is valid.
1. I have created READ_ONLY attribute for the date node (table).
2. I am filling the READ_ONLY to abap_true or abap_false based on the following condition.
Even if one of the projects is not valid for a date, then READ_ONLY = ABAP_TRUE. This means, even if one cell is set to abap_true, then READ_ONLY is set to abap_true.
3. I modify the date node and bind it with the READ_ONLY set row wise.
Loop at the data and set read only
navigate from <CONTEXT> to <DATE_TABLE> via lead selection
lo_nd_date_table = wd_context->get_child_node( name = wd_this->wdctx_date_table ).
CALL METHOD lo_nd_date_table->get_static_attributes_table
IMPORTING
table = lt_date_table .
LOOP AT lt_date_table INTO ls_date_table.
lv_tabix = sy-tabix.
READ TABLE wd_this->gt_prop INTO ls_prop INDEX lv_tabix.
IF sy-subrc EQ 0.
IF ls_prop-wk01 = abap_true OR
ls_prop-wk02 = abap_true OR
ls_prop-wk03 = abap_true OR
ls_prop-wk04 = abap_true OR
ls_prop-wk05 = abap_true OR
ls_prop-wk06 = abap_true OR
ls_prop-wk07 = abap_true OR
ls_prop-wk08 = abap_true OR
ls_prop-wk09 = abap_true OR
ls_prop-wk10 = abap_true OR
ls_prop-wk11 = abap_true OR
ls_prop-wk12 = abap_true OR
ls_prop-wk13 = abap_true OR
ls_prop-wk14 = abap_true OR
ls_prop-wk15 = abap_true.
ls_date_table-read_only = abap_true.
ELSE.
ls_date_table-read_only = abap_false.
ENDIF.
ENDIF.
MODIFY lt_date_table FROM ls_date_table INDEX lv_tabix TRANSPORTING read_only.
ENDLOOP.
CALL METHOD lo_nd_date_table->bind_table
EXPORTING
new_items = lt_date_table
set_initial_elements = abap_true.
4. I loop through the column reference and use the code mentioned earlier.
CREATE OBJECT lr_input
EXPORTING
value_fieldname = lv_id.
lo_column->set_cell_editor( value = lr_input ).
lr_input->set_read_only_fieldname( value = 'READ_ONLY' ).
The expected output is different from the input i had mentioned earlier for Row 1, row 2, Row 3 and row 4. Here, i would get all the rows as non editable except for Row 3.
I would want to set all columns based on condition.
Regards,
Rekha -
Event handling in alv oops With buttons
Hi Experts
I have some doubt in ALV OOPS using Events. Could any one please tell me the procedure to how to handle events in oops ( Like interactive reports using events ).
Thank you
Satyendra.Hello Satyendra
The following sample report shows you how to handle the event HOTSPOT_CLICK and BUTTON_CLICK.
DATA: gd_okcode TYPE ui_func,
gt_fcat TYPE lvc_t_fcat,
go_docking TYPE REF TO cl_gui_docking_container,
go_grid1 TYPE REF TO cl_gui_alv_grid.
DATA: gt_knb1 TYPE STANDARD TABLE OF knb1.
PARAMETERS: p_bukrs TYPE bukrs DEFAULT '2000' OBLIGATORY.
CLASS lcl_eventhandler DEFINITION.
PUBLIC SECTION.
CLASS-METHODS:
handle_hotspot_click FOR EVENT hotspot_click OF cl_gui_alv_grid
IMPORTING
e_row_id
e_column_id
es_row_no
sender, " grid instance that raised the event
handle_button_click FOR EVENT button_click OF cl_gui_alv_grid
IMPORTING
es_col_id
es_row_no
sender.
ENDCLASS. "lcl_eventhandler DEFINITION
CLASS lcl_eventhandler IMPLEMENTATION.
METHOD handle_hotspot_click.
* define local data
DATA:
ls_knb1 TYPE knb1,
ls_col_id TYPE lvc_s_col.
READ TABLE gt_knb1 INTO ls_knb1 INDEX e_row_id-index.
CHECK ( ls_knb1-kunnr IS NOT INITIAL ).
CASE e_column_id-fieldname.
WHEN 'KUNNR'.
SET PARAMETER ID 'KUN' FIELD ls_knb1-kunnr.
SET PARAMETER ID 'BUK' FIELD ls_knb1-bukrs.
CALL TRANSACTION 'XD03' AND SKIP FIRST SCREEN.
WHEN 'ERNAM'.*
SET PARAMETER ID 'USR' FIELD ls_knb1-ernam.
CALL TRANSACTION 'SU01' AND SKIP FIRST SCREEN.
WHEN OTHERS.
ENDCASE.
* Set active cell to field BUKRS otherwise the focus is still on
* field KUNNR which will always raise event HOTSPOT_CLICK
ls_col_id-fieldname = 'BUKRS'.
CALL METHOD go_grid1->set_current_cell_via_id
EXPORTING
is_row_id = e_row_id
is_column_id = ls_col_id.
ENDMETHOD. "handle_hotspot_click
METHOD handle_button_click.
* define local data
DATA:
ls_knb1 TYPE knb1.
READ TABLE gt_knb1 INTO ls_knb1 INDEX es_row_no-row_id.
CHECK ( ls_knb1-kunnr IS NOT INITIAL ).
SET PARAMETER ID 'KUN' FIELD ls_knb1-kunnr.
SET PARAMETER ID 'BUK' FIELD ls_knb1-bukrs.
CALL TRANSACTION 'XD03' AND SKIP FIRST SCREEN.
ENDMETHOD. "handle_button_click
ENDCLASS. "lcl_eventhandler IMPLEMENTATION
START-OF-SELECTION.
SELECT * FROM knb1 INTO TABLE gt_knb1
WHERE bukrs = p_bukrs
* Create docking container
CREATE OBJECT go_docking
EXPORTING
parent = cl_gui_container=>screen0
ratio = 90
EXCEPTIONS
OTHERS = 6.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Create ALV grid
CREATE OBJECT go_grid1
EXPORTING
i_parent = go_docking
EXCEPTIONS
OTHERS = 5.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Set event handler
SET HANDLER:
lcl_eventhandler=>handle_hotspot_click FOR go_grid1,
lcl_eventhandler=>handle_button_click FOR go_grid1.
* Build fieldcatalog and set hotspot for field KUNNR
PERFORM build_fieldcatalog_knb1.
* Display data
CALL METHOD go_grid1->set_table_for_first_display
CHANGING
it_outtab = gt_knb1
it_fieldcatalog = gt_fcat
EXCEPTIONS
OTHERS = 4.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Link the docking container to the target dynpro
CALL METHOD go_docking->link
EXPORTING
repid = syst-repid
dynnr = '0100'
* CONTAINER =
EXCEPTIONS
OTHERS = 4.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* ok-code field = GD_OKCODE
CALL SCREEN '0100'.
END-OF-SELECTION.
MODULE status_0100 OUTPUT.
SET PF-STATUS 'STATUS_0100'.
* SET TITLEBAR 'xxx'.
ENDMODULE. " STATUS_0100 OUTPUT
MODULE user_command_0100 INPUT.
CASE gd_okcode.
WHEN 'BACK' OR
'END' OR
'CANC'.
SET SCREEN 0. LEAVE SCREEN.
WHEN OTHERS.
ENDCASE.
CLEAR: gd_okcode.
ENDMODULE. " USER_COMMAND_0100 INPUT
FORM build_fieldcatalog_knb1 .
* define local data
DATA:
ls_fcat TYPE lvc_s_fcat.
CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
EXPORTING
* I_BUFFER_ACTIVE =
i_structure_name = 'KNB1'
* I_CLIENT_NEVER_DISPLAY = 'X'
* I_BYPASSING_BUFFER =
* I_INTERNAL_TABNAME =
CHANGING
ct_fieldcat = gt_fcat
EXCEPTIONS
inconsistent_interface = 1
program_error = 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.
LOOP AT gt_fcat INTO ls_fcat
WHERE ( fieldname = 'KUNNR' OR
fieldname = 'ERNAM' OR
fieldname = 'BUKRS' ).
IF ( ls_fcat-fieldname = 'BUKRS' ).
ls_fcat-style = cl_gui_alv_grid=>mc_style_button. " column appears as button
ELSE.
ls_fcat-hotspot = abap_true.
ENDIF.
MODIFY gt_fcat FROM ls_fcat.
ENDLOOP.
ENDFORM. " BUILD_FIELDCATALOG_KNB1
Regards
Uwe -
How to avoid roundtrip to server on value select in dropdown box in ALV cel
Dear Experts,
I have WD ALV table where user edits values in the cels using dropdown by key element.
Then after edit he saves whole table. When value is changed in dropdown box the roundtrip to server occurs and it takes noticable time for every cell. My dropdown lists are fixed and are the same for all rows. It is not pleasant user experience and is annoying for user.
Is there a way to disable this roundtrip for each value selection for each cell and transfer all the data for whole ALV table only when I save whole table (separate button "Save")?
Help very much appreciated.
DmitryA lot of enterprises, however, actively avoid systems which are locked down to a particular server for very legitimate reasons. If my data center dies in the middle of the night, I sure don't want to have to call your mobile phone so that you can get to a computer, log in to the office network, and get me a new key so that I can finish my emergency failover. If I've got dozens of applications, I absolutely don't want to do that with dozens of different vendors.
It sounds like your problem, though, isn't that users are installing your software on multiple computers it's that they are accessing functionality they haven't licensed. That is generally a much easier problem to solve and doesn't require you to lock anything down to a particular machine. You can create a table LICENSED_CONTENT, for example,
CREATE TABLE licensed_content (
client_id NUMBER,
content_type VARCHAR2(30),
key RAW(128)
)In this case, KEY is, say, a hash (using the DBMS_CRYPTO or DBMS_OBFUSCATION_TOOLKIT packages if you'd like) of the client_id, content_type, and a bit of salt (i.e. a fixed string that only you know). When you sell a license to manage diamond content, you provide a script that inserts the appropriate row in the LICENSED_CONTENT table. When your application starts up, it reads the LICENSED_CONTENT table and verifies the hash before allowing users to access that type of content. This allows legitimate customers to move the software from one system to another but prevents them from accessing new functionality without a new license.
Justin -
Hi,
what is the best way to get a large string into an ALV Grid cell?
Any help is greatly appreciated.
/ ElvezHi,
I suggest that you place a button on the column, and when clicked show a TEXT editor (CL_GUI_TEXTEDIT) in a DOCKING container with the text that you want.
Even if you use the full length of 255 for a column, for the user to see other columns, he has to scroll left / right.
Regards,
Ravi
Note : Please mark the helpful answers -
Hi!
I'm beginning with ALV's and i have a problem when saving the content of a grid to a Z table that i built.
So...i have one collum that is of type mseg-menge ( i declared like this: zfield like mseg-menge). When i fill in the ALV this cell (for example, with the number 10000) and then hit the save button (wich i control at user_command) it changes that value to 10,000 and saves to the Z table like '*00'.
Does anybody knows how can i solve this problem?
Regards,
RT.Why don't you see if the following code in the field catalog (assume structure is wa) does what you want. It suppresses the conversion exit.
wa-no_convext = abap_true.
Your target field may also be too narrow. You should make sure it is wide enough. -
Hello,
I have an ALV table, and some colums are of type text with quite long lengths.
Initially the columns have a small length, but when the user writes long texts (for example 100 characters) the cell will is automatically enlarged to show the complete text on the screen. That's quite annoying because with two or three columns like this, storing long texts, the overall width of the table is really big.
I know that there is a way to define fixed columns, but the problem with this is that then, when the long text is input in the table, you cannot scroll inside the cell to see the values, you can only see the beginning of the phrase.
I would like to do something similar to the Excel. First I would like to allow the users to resize the columns (just like the Excel grid) and then I would like to wrap long texts in different rows (inside the cell) to reduce the cell width.
Is this possible? What would you recommend in this case?
RegardsHi Javier,
The ALV resize functionality is there in 7.0 Enhp1. It works for standard tables and ALV. You only have to set the fixedTableLayout property to True. You can use the below link to check out Thomas Jung's [demonstration |http://www.flickr.com/photos/tjung/2806011790/]in which he shows as to how we can resize the ALV columns.
create an instance of ALV component
DATA: LR_IF_CONTROLLER TYPE REF TO IWCI_SALV_WD_TABLE,
LR_CMP_USAGE TYPE REF TO IF_WD_COMPONENT_USAGE,
LR_CMDL TYPE REF TO CL_SALV_WD_CONFIG_TABLE,
LR_TABLE_SETTING TYPE REF TO IF_SALV_WD_TABLE_SETTINGS.
LR_CMP_USAGE = WD_THIS->WD_CPUSE_ALV( ).
IF LR_CMP_USAGE->HAS_ACTIVE_COMPONENT( ) IS INITIAL.
LR_CMP_USAGE->CREATE_COMPONENT( ).
ENDIF.
get reference to the ALV model
LR_IF_CONTROLLER = WD_THIS->WD_CPIFC_ALV( ).
LR_CMDL = LR_IF_CONTROLLER->GET_MODEL( ).
LR_TABLE_SETTING ?= LR_CMDL.
Set column width
DATA LR_COL TYPE REF TO CL_SALV_WD_COLUMN.
LR_COL = LR_CMDL->IF_SALV_WD_COLUMN_SETTINGS~GET_COLUMN( 'PERNR' ).
LR_COL->SET_WIDTH( '70' ) .
LR_COL = LR_CMDL->IF_SALV_WD_COLUMN_SETTINGS~GET_COLUMN( 'ENAME' ).
LR_COL->SET_WIDTH( '100' ) .
LR_TABLE_SETTING->SET_FIXED_TABLE_LAYOUT( ABAP_TRUE ).
Regards,
Uday -
How can I change the active Midlet using the '*' cell phone button
Hello
I've got a problem trying to do that in J2ME MIDP:
'I have different class extending Midlet that I want to display one after the other. The change may be done when I click the '*' button of my cell phone'
For the moment I've created a main class that extend Canvas and which contain a vector of objects extending Midlet.
I'm able to change the objet which I want to display, but not to display it....
Is it possible to do that?
Do you have any idea of how to deal with that?
Thanks a lot...Hello
Thx for your answer .. but I shouldn't have explain correctly my problem because I don't think this answer it .. sorry
I need an interaction between a Midlet class and a Canvas class.
In fact I have several forms, and I need to allow my Canvas class to change the form displayed when a button is pressed.
But If I have a form in a Midlet , I can display it but can't catch the click on a button.
And if my Canvas is displayed I don't know how to display the form I want to.
So is it possible to do that... and if so, how?
Thank you very much...
Al161084
Message was edited by:
al161084.1 -
ALV cell translation when exporting to excel
Hi,
I am displaying an ALV with first column as traffic signal. When I export the ALV data to excel, nothing is displayed under traffic signal column.
My question is: When we are exporting ALV to Excel, can we substitute text for either red or yellow or green traffic signals?
For example:
If my first row in ALV is displaying traffic Red signal then when we export that to excel, in place of traffic Red Signal text 'NO' should be displayed.
If my second row in ALV is displaying traffic green signal then when we export that to excel, in place of traffic green Signal text 'YES' should be displayed.
Thanks in advance.Hi
I think we can't customize the SAP provided functionality to download in Excel from ALV grid.
Instead, we can create a button in application toolbar and we can add our customizing code when the
button is clicked, under user_command coding part.
For each icon (for traffic signal also), there will be four char code (like @OC@) in the ICON type pool.
In your code (for button in application toolbar), you have to check the value (for four char code) and
you can provide value (like NO) for that traffic signal (like RED).
But, in this method you have to take care about the data download from ALV grid to EXCEL.
Satya. -
ALV cell attributes CHANGE during DATA_CHANGED event
Hi,
I am working with CL_GUI_ALV_GRID in a splitter control. I am trying to make separate cells (non)editable depending on user input in the ALV. In event DATA_CHANGED (refefined) I change the cellstyle-table and then use method REFRESH_TABLE_DISPLAY.
My problem is: I can change contents of fields perfectly, but when I change a cell's editability, the cell is being showns as editable, but when I press F4 f.i. and look in debug, the cellstyles-table hasn't been updated and still reflects the old values.
Could anybody help me out?
Kind regards,
Roy
P.S. Obviously I will reward points to useful answers.Hi Nithya,
I am not making the field edit or no-edit using fieldcatalog-edit. This makes an emtire column editable. I only want to make individual cells editable.
I do this using a table that I have attached to the ALV's structure and linked using layout-stylefname. You gave me an idea though: I might have to use SET_SELECTED_CELLS or an equivalent.
Any other ideas that might be helpful?
Kind regards,
Roy -
ALV TOOL BAR BUTTONS NOT ENABLED IN TCODE FBL3N
Hello All,
We have currently switched from 4.7 to Ecc 6.0 and while executing
tcode FBL3N in ALV tool bar all the buttons like Change document , mass
change , select layout , save layout are disabled.
These all buttons are active in 4.7 but in ecc 6.0 these buttons are
totally disabled.
I have checked all these buttons fcode status in se41 and all that are
active.
Kindly guide us how to go about it.
Regards,
SunnyHi suny,
there are some new authority-objects in ecc6.
try SU53 after executing FBL3N.
Perhaps you find Authotity-Problems.
Regards, Dieter -
OO ALV Cell Merge Problem when editable fields
Hi there!
I'm using OO ALV ( CL_GUI_ALV_GRID ) and experiencing a strange problem.
I'm interested in the cells merging functionality of ALV, when i sort data for a specific field.
It works fine but only if i do not set any field as editable ( lvc_s_fcat-edit = 'X' ).
For some reason ALV loses some of its functionality when you set a field as editable.
I've noticed it also with the functionality of expanding/supressing data when using subtotals.
If any field is set as editable then subtotals come always expanded, you cannot supress them...
Has anyone else experienced somethng like this before? Any help will be appreciated!
BR
George ZervasHi,
Check This [Thread|http://forums.sdn.sap.com/thread.jspa?threadID=928573] to solve your issue.
Check the User Command, first line should be call method cl_gui->check_changed_data().
Check this [url|http://wiki.sdn.sap.com/wiki/display/ABAP/InteractiveEditableOOALVgridwithdynamicitab,FCATandENTERkeyeventtrigger] for code to work on Interactive Editable OO ALV grid .
Hope will solve your issue.
Regards,
Saravana.S
Edited by: saravanasap on Feb 14, 2012 7:38 AM -
Hi,
I want to make cell alignment in ALV.
I could able to do left and center alignment but not right alignment.
How to do the right alignment??
I'm using the below code:
data lr_salv_column type ref to cl_salv_wd_column.
lr_salv_column->SET_H_ALIGN( value = 1 ). "0 - right/ 1- center
Thankx,
SubaJatra Riwayanto wrote:>
> Hi,
>
> .....
> * set h.alignment
> LR_COL->SET_H_ALIGN( '06' ).
>
>
>
> Notes:
> '06' = FORCED RIGHT
> '05' = END OF LINE
>
> Regards,{quote}
Just a word of warning. You should avoid coding the values directly. SAP can change these values at any time and we won't applogize if that breaks your application. :) You should always use the class constants. This also makes your coding much more readable and maintainable. It also makes it easy to forward navigate and find all the possible values. For this example the class constants are CL_WD_TABLE_COLUMN=>E_H_ALIGN
Type defintion from CL_WD_TABLE_COLUMN:
begin of e_h_align,
auto type wdy_uie_library_enum_type value '00', " TableColumnHAlign.auto
center type wdy_uie_library_enum_type value '01', " TableColumnHAlign.center
forced_left type wdy_uie_library_enum_type value '04', " TableColumnHAlign.forcedLeft
end_of_line type wdy_uie_library_enum_type value '05', " TableColumnHAlign.endOfLine
forced_right type wdy_uie_library_enum_type value '06', " TableColumnHAlign.forcedRight
begin_of_line type wdy_uie_library_enum_type value '07', " TableColumnHAlign.beginOfLine
end of e_h_align .
So your coding should be:
LR_COL->SET_H_ALIGN( CL_WD_TABLE_COLUMN=>E_H_ALIGN-FORCED_RIGHT ).
Maybe you are looking for
-
Order Import Erroring while importing closed Order
Hello, I am working on importing closed order for historical purpose and order import is erroring without giving much details. I set the debug level to 5 and log file contains only one error' ORDER IMPORT FAIL DUE TO UNEXPECTED ERROR. I am attaching
-
SSRS reports : custom shapes
Hello, I have to generate DOCX, XLSX and PDF format with custom shapes. Attached is a sample of the report expected. The shapes contain data from DB. The color of the shapes will vary depending on the data from DB. e.g. the shape can be gray in one r
-
Hello, I am very new to APEX (i.e. have never used it before, but want to learn). I have a lot experience in writing SQL and some with PL/SQL. My background is primarily web development using ColdFusion, JavaScript, various flavors of SQL (T-SQL, PL/
-
Why won't iPhone 6 open jpg images?
i have new iPhone 6, but when someone sends a jpg image either by txt or email, the images won't open on the iPhone. The email images do open fine on my laptop. Is this a defect in the phone or the new operating system?
-
Why won't my iPhone 4s sync to my iTunes?
I am very frustrated with Apple right now! Today, I wanted to synch my phone to my iTunes to delete music from it and back it up. So, I plugged my phone in and it didn't show up on iTunes. So, I updated my phone. Still didn't show up. So I updat