How to prefix (-) sign in values column of ALV

Hi!! every one!!!
     can u please let me know how to prefix sign to the values in values column of ALV Report... when negative values r there  its giving sign after the value so how to prefix that sign to the value. please do the needful...
thanks in advance..
neelam.

us this
FM
call function 'CLOI_PUT_SIGN_IN_FRONT'
  changing
    value = itab-value.

Similar Messages

  • How to display subtotals in separate column in alv report?

    hi,
    I am displayed the subtotals  for QUantity field BDMNG in Reuse_alv_grid_display  in the same column.
    but I want to display subtotal in separate column.
    How to display subtotals in separate column in alv report?
    thanks&regards.
    samba.k

    Hi
    As far as i know you can't do this,the option you have is to create one more column (subtotal) and populate it by manual calculation at every subtotal (not alv subtotal but yours) .
    Best Regards
    Yossi

  • How to check sign of value ' - ' and ' + '.

    Hi Experts,
            can you tell me what is the preocedure to check the sign
    of value whether it would be ' - ' or ' + '.
             if i have to check the sign of -1100 then system should tell me the sign is ' - ' . how it can be possible.

    Hi,
    Try this.
    Check whether the value of variable say v1.
    If v1< 0.
    Then display the message as '  -  '.
    else.
    Then display the message as '  + '.
    endif.
    The message is according to your requirement.
    Sharin.

  • How to display sign in left side in ALV Grid Function module?

    Hi,
    How to Dispaly sign in left side for amount fields in ALV GRID function module?
    Ex : Amount = 1234-
    I want to dispaly it as -1234.
    Is there any option in ALV Grid function module?

    Hi sreedhar,
    Use FM  'CLOI_PUT_SIGN_INFRONT'
    it will giv the value like '-1234' if u pass '1234-'.
    DATA : v_field(17).
    MOVE v_amount to v_field.
    CALL FUNCTION 'CLOI_PUT_SIGN_IN_FRONT'
    CHANGING
        VALUE   = v_field.
    MOVE v_field to v_amount.
    OR
    FORM change_sign changing var type c.
    if var LT 0.
    shift var right deleting trailing  '-'.
    shift var left deleting leading  ' '.
    concatenate '-' var into var.
    else.
    shift  var left deleting leading  ' '.
    endif.
    ENDFORM.
    reward pts if it helps.
    Edited by: venkat reddy on Jan 2, 2008 7:19 AM

  • How to Change the position of Column in ALV report

    Hi Follks,
        Is is possible to change the position of column in ALV report?.If yes then how?
        Basically my requirement is, that user want afacility where , he should be able to change the position
        of column aftre he runs the report.
        Eg: After running the report , user felt that column 5 should be at position 2 , in that case he should   
               be able to drag column 5 at position 2 and vice versa.
        Please help me, how to solve this issue.
        Note : I am using NW 7.0 SP 9
        Regards
        PG
    Edited by: PG on Apr 13, 2009 11:10 AM

    HI PG,
    do below whie filling the filed catlog
    wa_fieldcat-fieldname        = 'Field1".
    wa_fieldcat-COL_POS = '1',
    append wa_fieldcat to it_fieldcat.
    wa_fieldcat-fieldname         = 'Field2".
    wa_fieldcat-COL_POS = '2',
    wa_fieldcat-fieldname         = 'Field3".
    wa_fieldcat-COL_POS = '3',
    Thanks!

  • How to hide headers for specified columns in ALV?

    Hallo guyes,
    is it possible to hide headers just for a few columns in ALV?
    Something like no_headers but just for defined columns...
    Is it also possible to define column description in two lines?
    Thanks.

    Hi,
    Check the below code
    codeFORM prep_fieldcat_xls USING lt_fieldcat_xls TYPE slis_t_fieldcat_alv.
    RANGES: lra_fieldname FOR field_ran.
    DATA: lwa_fieldcat_xls TYPE slis_fieldcat_alv.
    Build range for all unwanted columns:
    lra_fieldname-option = 'EQ'.
    lra_fieldname-sign = 'I'.
    lra_fieldname-low = 'EEP'.
    APPEND lra_fieldname.
    Remove the unwanted columns from the fieldcatalog:
    lt_fieldcat_xls] = lt_fieldcat[.
    LOOP AT lt_fieldcat_xls INTO lwa_fieldcat_xls
    if lwa_fieldcat_xls-fieldname = lra_fieldname-low. "Change here as it is
    lwa_fieldcat_xls-no_out = 'X'.
    endf.
    MODIFY lt_fieldcat_xls FROM lwa_fieldcat_xls INDEX sy-tabix.
    ENDLOOP.[/code]
    Regards,
    Raj.

  • How to set color to a column in ALV?

    Based on standard example BCALV_GRID_01 to modify,
    how to set color to a column???
    Moderator message: please search for available information/documentation before asking.
    Edited by: Thomas Zloch on Nov 6, 2010 9:43 AM

    Hi Sai ,
    you are posting the querry in the wrong forum ..
    but still I will answer ur querry...
    Incase you are not using the standard class to make your ALV then u can set the color of each column in the propertiesof column in the design time .
    Incase u see the colors in the design time but is not able to see the colors at the run time then you check the settings of the table I dont have system right now else I could have told you exact property...
    else if u r amking alv from the standard class then u will have to search the net for the method to color the same ..
    Thanks
    Sahil.

  • How to show financial period value columns in p6 web

    hi, is it possible to bring in the column of financial period value (.i.e when we use store period performance) in p6 web as we do in p6 client?

    I don't believe you can view it as a column, but you can add it to the Gantt. I tested it and it works in that view. See below....
    To manually adjust the timescale, in the top section of the timescale header,
    click and release the mouse. Then, drag the horizontal arrow that appears.
    To change the timescale setting (for example, Quarter/Month or Financial
    Period), either right-click in the timescale header row or choose timescale
    increments from the Customize View Bars tab.
    Tip: If the Financial Period timescale option is available,
    choose it to display the range of financial periods defined in the Project
    Management module.

  • How to get '%' Sign in a column

    Hi,
    I'm trying to calculate Percentage and would like to see it's sign (%) in front of the result...
    Can anybody help me with sort of Column settings?
    Thank you.
    Jitendra

    Hi Madan,
    It's a correct reply if i hv column added into my repositoy.
    But what if am calculating the column as "New Calculated Item" and adding it in Pivot as another column? will this work?
    Coz there is no format function for it.
    Jitendra

  • How to put colours for a column in ALV

    Dear All,
    I need to put green colour for 1 column in an ALV report.
    Can anybody tell me how we can do that ...
    Thanking you in advance,
    Shankar

    Here's a little sample program.....  this illistrates coloring at the column, row, and cell level.
    report zrich_0002 .
    * Use of colours in ALV grid (cell, line and column)            *
    * Table
    tables : mara.
    * Type
    types : begin of ty_mara,
              matnr         like mara-matnr,
              matkl         like mara-matkl,
              counter(4)    type n,
              free_text(15) type c,
              color_line(4) type c,           " Line color
              color_cell    type lvc_t_scol,  " Cell color
    end of ty_mara.
    * Structures
    data  : wa_mara     type ty_mara,
            wa_fieldcat type lvc_s_fcat,
            is_layout   type lvc_s_layo,
            wa_color    type lvc_s_scol.
    * Internal table
    data : it_mara     type standard table of ty_mara,
           it_fieldcat type standard table of lvc_s_fcat,
           it_color    type table          of lvc_s_scol.
    * Variables
    data : okcode like sy-ucomm,
           w_alv_grid          type ref to cl_gui_alv_grid,
           w_docking_container type ref to cl_gui_docking_container.
    parameters : p_column as checkbox,
                 p_line   as checkbox,
                 p_cell   as checkbox.
    at selection-screen output.
      perform get_data.
      perform fill_catalog.
      if w_docking_container is initial.
        perform create_objects.
      endif.
    *&      Form  create_objects
    form create_objects.
      create object w_docking_container
        exporting
          ratio                       = 60
        exceptions
          cntl_error                  = 1
          cntl_system_error           = 2
          create_error                = 3
          lifetime_error              = 4
          lifetime_dynpro_dynpro_link = 5
          others                      = 6.
      create object w_alv_grid
        exporting
          i_parent          = w_docking_container.
    * Field that identify color line in internal table
      move 'COLOR_LINE' to is_layout-info_fname.
    * Field that identify cell color in inetrnal table
      move 'COLOR_CELL' to is_layout-ctab_fname.
      call method w_alv_grid->set_table_for_first_display
        exporting
          is_layout                     = is_layout
        changing
          it_outtab                     = it_mara
          it_fieldcatalog               = it_fieldcat
        exceptions
          invalid_parameter_combination = 1
          program_error                 = 2
          too_many_lines                = 3
          others                        = 4.
    endform.
    *&      Form  get_data
    form get_data.
      select * from mara up to 5 rows.
        clear : wa_mara-color_line, wa_mara-color_cell.
        move-corresponding mara to wa_mara.
        add 1                   to wa_mara-counter.
        move 'Blabla'           to wa_mara-free_text.
        if wa_mara-counter = '0002'
        and p_line = 'X'.
    * Color line
          move 'C410' to wa_mara-color_line.
        elseif wa_mara-counter = '0004'
        and p_cell = 'X'.
    * Color cell
          move 'FREE_TEXT' to wa_color-fname.
          move '6'         to wa_color-color-col.
          move '1'         to wa_color-color-int.
          move '1'         to wa_color-color-inv.
          append wa_color to it_color.
          wa_mara-color_cell[] = it_color[].
        endif.
        append wa_mara to it_mara.
      endselect.
    endform.
    *&      Form  fill_catalog
    form fill_catalog.
    * Colour code :                                                 *
    * Colour is a 4-char field where :                              *
    *              - 1st char = C (color property)                  *
    *              - 2nd char = color code (from 0 to 7)            *
    *                                  0 = background color         *
    *                                  1 = blue                     *
    *                                  2 = gray                     *
    *                                  3 = yellow                   *
    *                                  4 = blue/gray                *
    *                                  5 = green                    *
    *                                  6 = red                      *
    *                                  7 = orange                   *
    *              - 3rd char = intensified (0=off, 1=on)           *
    *              - 4th char = inverse display (0=off, 1=on)       *
    * Colour overwriting priority :                                 *
    *   1. Line                                                     *
    *   2. Cell                                                     *
    *   3. Column                                                   *
      data : w_position type i value '1'.
      clear wa_fieldcat.
      move w_position to wa_fieldcat-col_pos.
      move 'MATNR'    to wa_fieldcat-fieldname.
      move 'MARA'     to wa_fieldcat-ref_table.
      move 'MATNR'    to wa_fieldcat-ref_field.
      append wa_fieldcat to it_fieldcat.
      add 1 to w_position.
      clear wa_fieldcat.
      move w_position to wa_fieldcat-col_pos.
      move 'MATKL'    to wa_fieldcat-fieldname.
      move 'MARA'     to wa_fieldcat-ref_table.
      move 'MATKL'    to wa_fieldcat-ref_field.
    * Color column
      if p_column = 'X'.
        move 'C610'     to wa_fieldcat-emphasize.
      endif.
      append wa_fieldcat to it_fieldcat.
      add 1 to w_position.
      clear wa_fieldcat.
      move w_position to wa_fieldcat-col_pos.
      move 'COUNTER'  to wa_fieldcat-fieldname.
      move 'N'        to wa_fieldcat-inttype.
      move '4'        to wa_fieldcat-intlen.
      move 'Counter'  to wa_fieldcat-coltext.
      append wa_fieldcat to it_fieldcat.
      add 1 to w_position.
      clear wa_fieldcat.
      move w_position  to wa_fieldcat-col_pos.
      move 'FREE_TEXT' to wa_fieldcat-fieldname.
      move 'C'         to wa_fieldcat-inttype.
      move '20'        to wa_fieldcat-intlen.
      move 'Text'      to wa_fieldcat-coltext.
      append wa_fieldcat to it_fieldcat.
    endform.
    Regards,
    Rich HEilman

  • How to control the visibility of column in ALV

    Hi,Expert,
    I'm using class CL_GUI_ALV_GRID to dispaly informations,but I want to hide
    some columns using code,how could I achieve that?
    Thanks a lot

    Hi Ray,
    Herewith a portion of sample code to hide the columns.
      DATA : wa_fieldcat_alv TYPE LINE OF lvc_t_fcat ,
                 it_fieldcat_alv TYPE lvc_t_fcat .
        Create ALV Field Catalog utk Header
          CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
            EXPORTING
              i_structure_name = 'ZP119H'
            CHANGING
              ct_fieldcat      = it_fieldcat_alv[].
          LOOP AT it_fieldcat_alv[] INTO wa_fieldcat_alv.
            CASE wa_fieldcat_alv-fieldname .
                 WHEN 'HIDE1'.
                        wa_fieldcat_alv-no_out = 'X'.
                 WHEN 'HIDE2'.
                        wa_fieldcat_alv-no_out = 'X'.
                 WHEN 'HIDE3'.
                        wa_fieldcat_alv-no_out = 'X'.
            ENDCASE.
            MODIFY it_fieldcat_alv FROM wa_fieldcat_alv.
          ENDLOOP.
    Rgds,
    TS WINEDYA

  • How to hide data of any column in ALV Display

    Hi ,
    I  am displaying  an  ALV in which i have to display subtotal  of each column but want to hide the data of  that column(only data is to hide ) column should be visiable,.
    Please let me know i any one have worked with this situation.
    Thanks in advance.

    Hi,
    In field Catlog set field no_out eq 'X'.
    No_out (field in field list): This parameter is used to remove certain fields from the output during initial display.  The user can however interactively choose the field for output from the field list in the display variant.
                       'X' = field is not displayed in the current list.
            Value set: SPACE, 'X'.
    Thanks & regards,
    ShreeMohan

  • How to show $ sign alongwith the value in message styled text field.

    Hi,
    How to show $ sign alongwith the value in message styled text field.
    The value is coming from the table column in VO.
    I am working on OAF R12.

    Hi,
    Resolved.
    I used the below code in CO for the solution.
    Formatter currencyFormatter = new OADecimalValidater("$#,##0.00;($#,##0.00)",
    "$#,##0.00;($#,##0.00)");
    OAMessageStyledTextBean msrpField = (OAMessageStyledTextBean)webBean.findChildRecursive("MSRP11");
    msrpField.setAttributeValue(ON_SUBMIT_VALIDATER_ATTR, currencyFormatter);

  • From two given tables, how do you fetch the values from two columns using values from one column(get values from col.A if col.A is not null and get values from col.B if col.A is null)?

    From two given tables, how do you fetch the values from two columns using values from one column(get values from col.A if col.A is not null and get values from col.B if col.A is null)?

    Hi,
    Use NVL or COALESCE:
    NVL (col_a, col_b)
    Returns col_a if col_a is not NULL; otherwise, it returns col_b.
    Col_a and col_b must have similar (if not identical) datatypes; for example, if col_a is a DATE, then col_b can be another DATE or it can be a TIMESTAMP, but it can't be a VARCHAR2.
    For more about NVL and COALESCE, see the SQL Language manual: http://docs.oracle.com/cd/E11882_01/server.112/e26088/functions119.htm#sthref1310
    I hope this answers your question.
    If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all tables involved, and also post the results you want from that data.
    Explain, using specific examples, how you get those results from that data.
    Always say which version of Oracle you're using (e.g., 11.2.0.2.0).
    See the forum FAQ: https://forums.oracle.com/message/9362002

  • How to get all the values in one column of a JTable

    How to get all the values in one column of a JTable as a Collection of String.
    I don;t want to write a for loop to say getValueAt(row, 1) eg for 2nd column.

    I don;t want to write a for loop to say getValueAt(row, 1) eg for 2nd column. You could always write a custom TableModel that stores the data in the format you want it. It would probably be about 50 lines of code. Or you could write a loop in 3 lines of code. I'll let you decide which approach you want to take.

Maybe you are looking for

  • I NEED HELP! How do you Create a Drop Down Accordion Navi with the child pages remaining expanded

    I would like to know how I can create a vertical accordion navigation with some custom modifications. I need it to function like this sites vertical navigation. (link is below)  Click on the parent page "bedrooms" and it expands revealing all of the

  • Apple tv and headsett

    can i stream video's from my iphone to apple tv, and get the sound from a headset connectet to my iphone?

  • Table for GL Carry forward balance

    Hi Can any one tell me the table where the carry forward balance of GL is stored.  Actually when we do faglgvtr the system will carry forward the previous year balances to the current year.  I want to know in which table those balances are stored . t

  • Checkbox renderer

    Hi i have a data grid with one of its column having check box as renderer. check box is visible for only some rows based on a condition.and this condition is in a function which is called from updateDiaplayList() function. but,the checkbox some how a

  • TS1702 Retrieve info from Icloud

    How do I upload info from the icloud?  I lost all info on LISTS and wanted to retrieve uploaded LISTS from Icloud.