SAPUI5: How to set the appearance of Table control?

Hi there,
I have a table on my app UI. Now I want simply show the table grid lines (currently, the vertical lines between columns are not shown). Any idea?
Furthermore, how to set the width of the bord lines or even teh color of the lines?
Thanks very much in advance!
Dong Zhu

Hi,
The demo link provided by Chandra uses Blue Crystal theme, hence it shows the vertical lines between the columns of the table. If you are using Gold Reflection theme, then to get the vertical lines, you need to play with CSS. Add the below snippet of CSS between <head></head> of your html file.
<style>
.sapUiTableTr>td {
              border-right: 1px solid #cccccc !important;
</style>
Thanks & Regards,
Vishwa

Similar Messages

  • Reg:How to delete the column in table control also from database table.

    Hi Experts,
    Once again thank u all for giving the responses.
    one more doubt is how to delete the columns of table control and also the record shold delete from ztable.
    With Regards,
    Saroja.P.

    Hi,
    If you want to delete the rows in the table control and simultaneously delete it from the database table, then you can implement a 'DELETE' functionality specific to your table control. Have a MARK field (you will find that in the screen attributes of the table control -> give a name for the MARK field, you will find an additional MARK column at the beginning of your table control). You can check whatever rows you want to delete from the table control, call the delete module.
    "This portion of code inside the LOOP...ENDLOOP.
    IF sy-ucomm eq 'F_DELETE'.
       gt_itab2-check = mark.  " Store the MARK field status into your internal table's correspoding field 'check'
      MODIFY gt_itab INDEX tabcontrol-current_line.
    ENDIF.
    iF sy-ucomm eq 'DELETE1'.
      DELETE gt_itab WHERE check eq 'X'. "Your internal table does not have rows that you want to delete
    ENDIF.
    Now you can modify your database table using the MODIFY statement.
    MODIFY ZDB FROM TABLE gt_itab.

  • Set the cursor on table control

    Hi All,
    I am trying to create a table control.
    Creation of table control is fine and i can update and save the records..But i am facing some strange problems.
    When i close my program and rerun it, the Cursor will be position on the default field of last run.
    How can we position the cursor on table control..Say to a particular row or columns?
    Also i am not able to interpret the meaning of
    Loop at itab with control control name cursor top_line/current_line.
    Does this means that if you use top_line, cursor will be placed at the top line and when you use current_line , it will be placed at current line?
    Regards
    Miesh

    Hi,
    Check this link for sample code for Table Control
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.highlightedcontent?documenturi=/library/webas/abap/abapCodeSamples/TableControlin+ABAP.pdf
    http://members.aol.com/_ht_a/skarkada/sap/table_control/table_control.htm
    Re: Table Control
    Thanks & Regards,
    Judith.
    Message was edited by: Judith Jessie Selvi

  • How to delete the row in table control with respect to one field in module pool programming?

    Hi,
    Can I know the way to delete the row in table control with respect to one field in module pool programming
    Regards
    Darshan MS

    HI,
    I want to delete the row after the display of table control. I have created push button as delete row. If I click on this push button, the selected row should get deleted.
    I have written this code,
    module USER_COMMAND_9000 input.
    DATA OK_CODE TYPE SY-UCOMM.
    OK_CODE = SY-UCOMM.
    CASE OK_CODE.
         WHEN 'DELETE'.
            LOOP AT lt_source INTO ls_source WHERE mark = 'X'.
                APPEND LS_SOURCE TO LT_RESTORE.
                DELETE TABLE LT_SOURCE FROM LS_SOURCE.
                SOURCE-LINES = SOURCE-LINES - 1.
            ENDLOOP.
    But I'm unable to delete the selected rows, It is getting deleted the last rows eventhough I select the other row.
    So I thought of doing with respect to the field.

  • How to set column attributes in table control?

    I have the following requirement to build a table by using table control:
    if content of col 1 = 'Y', enable input for col 2 for that line only.
    if content of col 1 = 'N', disable input for col 2 for that line only.
    So the input attribute for col 2 in each line can be different.
    How can I achieve this?
    I have tried using loop at screen or loop at tablecontrol-cols into wa_cols statements,
    but these will change the entire column attributes to either on or off, and not on individual line.
    Instead of changing the COLUMN attributes, I think I should change the CELL attributes. 
    What is the syntax for that, is there something like tablecontrol-field?
    Thanks for any help in advance.

    I still not able to get the field attributes set on individual lines.
    These are my codes, can you help again.
    PROCESS BEFORE OUTPUT.
      MODULE pbo_0200.
      MODULE zitem_change_tc_attr.
      LOOP AT   lt_asset_item
           INTO ls_asset_item
           WITH CONTROL zitem
           CURSOR zitem-current_line.
        MODULE ZITEM_CHANGE_FIELD_ATTR.
        MODULE zitem_get_lines.
      ENDLOOP.
    MODULE zitem_change_field_attr OUTPUT.
    loop at screen.
      if ls_asset_item-replace_asset = 'X'.
         if screen-group1 EQ 'FR4'.        "these are the columns I want to turn input ON or OFF.
          screen-input = '1'.
          modify screen.
         endif.
      endif.
    endloop.
    Endmodule.
    At debug mode, the screen-input did change to '1'.  Can I check the return code of the MODIFY SCREEN statement?
    I tried to initialize the colums to be output only at screen definition, but it still doesn't help.
    I don't think I have to do anything at the PAI event.
    PROCESS AFTER INPUT.
    MODULE save_cursor_position.
      LOOP AT lt_asset_item.
       FIELD ls_asset_item-replace_asset
         MODULE get_replace_asset ON REQUEST.
        CHAIN.
         FIELD LS_ASSET_ITEM-REPLACE_ASSET.
         FIELD ls_asset_item-replace_cost.
          MODULE zitem_modify ON CHAIN-REQUEST.
        ENDCHAIN.
        FIELD ls_asset_item-mark
          MODULE zitem_mark ON REQUEST.
      ENDLOOP.
      MODULE zitem_user_command.
    Thanks again.

  • HOW TO MAKE THE FIELDS ON TABLE CONTROL SCREEN FIXED!!

    Dear all,
    Can you please tell me as to how to make the fields on the table control screen fixed (not respond to the scroll bar) i.e. simillar to MC88 screen , the first two fields are fixed and don't respond to the scroll.
    Please Help!!!!
    Vj

    Hi
    In TC, goto attributes and set 'Fixed columns' as 2. This will fix the first 2 columns.
    Regards
    Navneet

  • How to clear the contents of table control

    Hi All,
              How to clear the contents that are present in a Table control. If there is any code Please Let me know.
    I will assign full marks to the correct code.
    Pradeep Kumar Kota.

    Hi
    U need to clear the contenents of internal table used to store the record displayed by table control.
    Every time the PBO is triggered the table control is automatically cleared, so you need only not to transfer any data from internal table to table control.
    So you should show how your PBO if you want a right answer.
    Max

  • How to color the records in table control.

    Hi,
    I have created a table control in which i want to add colors to it.
    It is possible in reporting,but is it possible in table control.

    You can do it,
    Just follow the code,...
    In PBO...
    PROCESS BEFORE OUTPUT.
    MODULE STATUS.
    LOOP WITH CONTROL TABCTRL.
    MODULE MODIFY_100.
    ENDLOOP.
    MODULE MODIFY_100 OUTPUT.
    DATA wa_tabctrl TYPE cxtab_column .
    LOOP AT TABCTRL-COLS INTO WA_TABCTRL.
          IF WA_TABCTRL-INDEX =  '1'.       "1- Your Respective Field Column's index
            WA_TABCTRL-SCREEN-COLOR = '2'. "Give your colour
            MODIFY TABCTRL-COLS FROM WA_TABCTRL.
          ENDIF.
    ENDLOOP.
    ENDMODULE.

  • SAPUI5 : How to set the date value format for DateTimeInput?

    Hi SAPUI5 experts:
    I'd like ask 2 things regarding the control: sap.m.DateTimeInput
    1: Here is I want to do: show the current date (May 1, 2014) in the control in format as "01-05-2014". But by default the following code shows "May 1 2014". How can I show it as "01-05-2014"?
    var oDateTimeInput = new sap.m.DateTimeInput({});
    oDateTimeInput.setDateValue(new Date());                   //shown as "May 1 2014"
    2. Can someone explain what difference is between the following settings of DateTimeInput?
       ValueFormat
       DisplayFormat
    Please write a short code example.
    Thanks very much in advance!
    Br,
    Dong

    Hi,
    to understand ValueFormat and DisplayFormat, you can refer this example from ui5 testsuite sap.m.DateTimeInput and check the source code.
    in one of the example, this is how valueformat and displayformat is used.
    // free style date value assingment according to valueFormat
                                                    dti3 = new sap.m.DateTimeInput({
                                                                    value : "05-29, 2012",
                                                                    valueFormat : "dd-MM, yyyy",
                                                                    displayFormat : "dd MMMM, yyyy",
                                                                    width : "20%",
                                                                    change : function(e) {
                                                                                    console.log(dti3 + " : " + e.getParameters().newValue + " # " + e.getParameters().newDateValue);
    also in both cases, Default value is taken from locale settings.
    Regards,
    Chandra

  • How to set the font for table view contol

    Dear All,
    My requirement is to set Font type = Arial and size=1 for
    Table View control. The same font should be for  header, Rows and footer.
    One way we are achieving it through the Renderer class. Where in we are we are supplying data, colums with html font tags.
    Is there any simple way to fix font fot the entire TableView.
    Thanks
    Markandeya

    An approach I've used is to override the CSS styles by adding code like the following to the top of the JSP page.  It's a bit of a hack, but it did the job.  You will need to find ALL the styles used in a table view, and override the font size.
    <%-- OVERRIDE SOME CSS STYLES SO WE HAVE THE DESIRED TABLE CELL PADDING --%>
    <style>
    <!--
    .sapTbvCellStd {
         PADDING-RIGHT: 2px; PADDING-LEFT: 2px; PADDING-BOTTOM: 0px; PADDING-TOP: 0px
    .sapTbvCellAlt {
         PADDING-RIGHT: 2px; PADDING-LEFT: 2px; PADDING-BOTTOM: 0px; PADDING-TOP: 0px
    //-->
    </style>

  • How to set the size of a control with the mouse ?

    hi all,
    i am writing a sort of ide (editor which creates applets very easy....) - for this purpose i need some hints from you guys:
    of course i need to create some controls like buttons...
    no prob - i am able to create buttons and place them at any place.
    BUT WHAT ABOUT THE SIZE ?
    ok, i have some ideas to realize this but what i want is a thick border arround the control with spots at each corner - when i place the cursor at one of these spots, my mouse cursor should change and it must be able to change the size of the control (while pressing and moving the mouse - you all know that from any ide).
    so how to do that?
    go on brains!!!
    THANX,
    andi

    I thought about creating dynamically resizable components, but gave it up as the effort seems too much for the benefit. I did a search for info on it and found a lot of people who wanted to do it, but not any who had actually done it completely. Here's some of my thoughts on the subject. You are right on about creating 'sizing handles', it seems to me the way to do this is to create your own container for any component (extend JPanel?) which can switch between no border and your new sizing border at some event. You will need to respond to mouse clicks on this border and follow the 'drag' event to find out where it was dropped. The java drag/drop events probably won't be of any use to you because each component will need an event handler. You need to catch them all.
    Finally, you need to figure out how to interact with some LayoutManager or write your own. Most LayoutManagers want to do their own resizing and you will have to deal with this. For example, GridBagLayout will not only resize all of the other components on the affected row and column, but unless you resize the other components, you won't be able to drag the top higher or the left lefter?

  • How to set the Rman backup parameter.

    Hi,
    Can U guide me how to set the Rman backup path,control file auto backup & others parameter.

    Hi,
    Go through this,
    Show all configurable settings:
    RMAN>SHOW ALL;
    Write disk backups to the /rmanback directory: (%U will be replaced with unique filenames)
    RMAN> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/rmanback/%U';
    Backup using a flash recovery area rather than disk
    RMAN> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT CLEAR;
    Configure RMAN to back up the control file after each backup
    RMAN> CONFIGURE CONTROLFILE AUTOBACKUP ON;
    By default, RMAN automatically names control file backups and stores them in the flashrecovery area.
    To configure RMAN to write control file backups to the /backup directory:( %F will generate a unique filename)
    RMAN> CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backup/controlfile%F';
    Ensure that RMAN retains all backups needed to recover the database to any point in time in the last 7 days:
    RMAN> CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
    Retain three backups of each datafile:
    RMAN> CONFIGURE RETENTION POLICY TO REDUNDANCY 3;
    Delete backups no longer required by the retention policy:
    RMAN> DELETE OBSOLETE;
    To override the configured retention policy for individual backups - use BACKUP.. KEEP (or CHANGE.. KEEP)
    Configure backups to run in parallel by assigning two sbt channels:
    RMAN> CONFIGURE DEVICE TYPE sbt PARALLELISM 2;
    Reset any CONFIGURE setting to its default by running the command with the CLEAR option
    RMAN> CONFIGURE CHANNEL DEVICE TYPE sbt CLEAR;
    RMAN> CONFIGURE RETENTION POLICY CLEAR;
    Regards,
    oraclekt
    Edited by: oraclekt on Sep 1, 2010 9:58 PM

  • How to set the table input in Query template?

    Hi all.
    I need to call a Bapi_objcl_change, with import parameter and a table as an input. I have done this, in BLS. I have set the table input in the
    form of xml. In BLS, I get the output(the value gets change in SAP R3, what i have given in BLS).  But if i set the same xml structure  in
    query template, I didn't get the output. Table input parameter does not take that xml source.  How to set the table input in Query template?
    can anyone help me?
    Regards,
    Hemalatha

    Hema,
    You probably need to XML encode the data so that it will pass properly and then xmldecode() it to set the BAPI input value.
    Sam

  • How to get the values from table region and how to set

    Hi,
    I have a requirement as Seeded Page Having One Table Region having around 8 columns, In That Item Description field is there. My Requirement is I need add one more field for that Region and assign the value depending Item Description.
    I will create one new Item in that region and will give name as Item, But how to set the values to Item Depending on Item Description.
    Is it possible to through CO Extension, If yes..Pls help how to get it.
    Thanks in Advance,
    Hanimi

    Hi Hanimi,
    1. You need to extend the VO, add a new Attribute.
    2. In VORowImpl of the extended VO, you can find the getter for your new attribute (example getItem())
    3. In this getter method you can write some code like:
    if("ABC".equals(getItemDescription())
    return "XYZ" ;
    -Prince
    http://princekapoor82.blogspot.com

  • How to set border lines in table and also in template in the smartforms ?

    How to set border lines in table and also in template in the smartforms ?
    As I have to create table with following detals
    total row = 3
    row1 = 3 column
    row2 = 6 column
    row3 = 9 column
    for 2nd and 3rd row data to be fetched using coding.
    so can anybody explain me what should i use
    Table or Template ?
    and I want the border like excel format.
    Can anybody suggest me ?
    Thanks
    naresh

    if the data is multiple i.e. line items choose table.
    if the data is single i.e. fixed choose template.
    Create table
    >  Draw u r no lines
    > choose option select pattern
    > select display framed patterns
    Choose u r required one.
    out lined, or full lined. u can choose option.
    same procedure to be followed for template also.
    with regards,
    Kiran.G

Maybe you are looking for

  • My email/password won't work, I request a reset, re-register but no confirmatory email received

    I responded to a Firefox email which resulted in my changing my theme by mistake. I wanted to change it back. That was about three hours ago. I tried to login to my account using the username, email and password I had written down for Firefox. They w

  • Crap BT handsfree voice quality using MEGA PLAYER 522BT

    It has been more than 2 months since I bought my MEGA PLAYER 522BT. Initially, I was thinking of using this as my handsfree, but th evoice quality is really some crap! Eversince then, I have been checking the MSI download page in hope for new FW to i

  • Problem in IE with centering.

    Hi, I am new to Dreamweaver. I have created a page in html. It has a table. I set the location of the table with percentage for different resolutions. In chrome it works perfectly but in IE (using IE 7) its aligned to the left. Any idea what I should

  • DQM for SAP - Quarterly Adjustment reports

    Hi, Can someone sheds some light on how the Quarterly Adjustment Reports in DQM work for pre-load u201CCleansed Addressesu201D? I know when scheduling the first report (RSADRQU1), we have the following options: 1.     No Unchecked addresses. 2.     I

  • Unknown "from" email address when I compose new email

    Hello, Starting last night, I noticed that when I go to compose a new email, an unknown email address defaults into the "From" section of the new email. If I pull down on the unknown address, my real address is there, but not selected. I can select i