Display Currency symbol with value in ALV Report
Hi Experts,
I need to display currency symbol with value in ALV Report like if currency type is dollar then $200.
Here I am using field catalog type slis_t_fieldcat_alv and suing field merge catalog FM: 'REUSE_ALV_FIELDCATALOG_MERGE'
I tried like this
IF <fs_fieldcat>-fieldname = 'STPRS'.
<fs_fieldcat>-seltext_s = 'Std Cost '.
<fs_fieldcat>-seltext_m = 'Std Cost'.
<fs_fieldcat>-seltext_l = 'Std Cost '
<fs_fieldcat>-tabname = 'MBEW'.
<fs_fieldcat>-ctabname = 'T001'.
<fs_fieldcat>-cfieldname ='WAERS'.
<fs_fieldcat>-datatype = 'CURR'.
ENDIF.
Please any one can suggest the solution for this.
Advance Thanks.
Regards,
Bala Achari
Hİ,
Check this link.
http://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=24379571
Take care.
Çağatay
Similar Messages
-
How to display Currency Unit beside value in BEx Report?
Hi,
I have 2 separate Amounts in the columns area. Their respective currencies exist as Characteristics in Unit dimension. How do I display the amount along with currency unit beside it?
As of now my Report looks like....
Amount 1 Amount 2
2000 3000
I would like to display it as......
Amount1 CUR Amount2 CUR
2000 EUR 3000 USD
Thanks,
SD
Edited by: Sebastian D'Souza on Jan 16, 2009 11:40 AMHi Sebastian,
Yes it can be possible to get the currency unit along with currency in ur report.
To do this, first of all u need to have the currency unit in ur flat file or else in ur data.
If u have so, here are the steps to do that.
1.Double click ur amount info object under 'currency/unit of measure tab' , in the unit/currency field just give as 0currency.
2.And then activate ur info object.
3.In Transformations u will find another field '0currency', just map it to the amount field.
and then do the process as usally loading data to target, and the execute the report.
u will be able to see currency unit filed also.
hope this helps u.
Thanks,
Sai Chand. -
Our Crystal Report displays money fields (from our SQL database).
Our Crystal Reports Designer has the Display Currency Symbol feature disabled by default when writing reports.
On one report we have a Sell_Amount currency field to display:
We have this Sell_Amount field directly on the report in one section.
We also have this Sell_Amount field in a formula for printing in a different section. This formula is defined as a text field as it will either display 'No Charge' or the Sell_Amount based on a condition, such as: If {NoCharge} Then 'No Charge' Else ToText(Sell_Amount)
When viewing this report on our development machine in Crystal Designer, the Currency Symbol does not show for either the Sell_Amount field that is directly on the report or for the Sell_Amount that is in the formula (I am guessing because we have the Display Currency Symbol disabled).
When viewing on a runtime machine (no Designer, just runtime components), the formula (if NoCharge = False) displays the Sell_Amount (in the formula) WITH the currency symbol, but the Sell_Amount that is directly on the report (not in the formula) does not display the currency symbol. Why?
This has been an issue ever since were were on Crystal 8 way back when. We have never found (nor asked) for a reason, but now we need to know the reason/rules, etc. for this. We are currently on Crystal 2008 SP6 (Designer) and deploying Crystal Reports Developer for Microsoft Visual Studio SP6 runtime components. As I said, this has been an issue for years, but we now need an explanation. I have not been able to locate one on the site anywhere. Can you please explain the rules of Currency Symbol in this scenario?
Thank you.Hi NB,
I did say to use the Advanced editor but I did not say to use it for attaching the report...
So to be clear here is what I see in the report Designer ( I put the formula into text boxes also ):
For the NoDatabaseCurrency field you have to set the currency to Fixed, Floating will add a space:
Which is opposite of what you originally posted:
"...Our Crystal Reports Designer has the Display Currency Symbol feature disabled by default..."
It's not disabled by default, please explain?
As for using the CCUR() function the help file does show the Currency symbol is on by default:
Examples
The following examples are applicable to both Basic and Crystal syntax:
CCur (200.20)
In Crystal syntax this is equivalent to writing $200.20. In Basic syntax, CCur (200.20) is the way to directly create a Currency value of 200.20.
CCur ("$200.20")
Returns the Currency value CCur (200.20) given the String value "$200.20".
CCur ("two hundred dollars")
Causes an error to occur. The CCur function cannot convert the String "two hundred dollars" to a Currency value.
So if you mean you went into the Options menu and Fields, Currency and check off this option:
[Update] - After testing this a few times it does retain the Options, current, Display Currency Symbol, so creating a new report the option is unchecked.
You are correct, even though I checked it off when I create a new report the option is checked on and obviously it's still on for each field and object. This may be a bug, testing more and checking with a few more people and eventually R&D.
So please clarify the steps you are doing?
Make sure you are running CR Designer under local PC Admin rights, right click on the short cut and select run as Administrator or check this option on:
Thanks
Don -
How to ceate a new Country key,currency ,version and value type for report
hi,
can you please let me know How to ceate a new Country key,currency ,version and value type for report
along with tables and tcodes.
thanking youNot clear on your comments
How to ceate a new Country key,currency,
version and value type for report
because in one line you are saying you want to create Country Key, which means your requirement is in some transaction whereas at the end, you say for report.
Can you let us know you want to develop a report and if so, from which transactions, you want to take datas. You have to be clear on this.
thanks
G. Lakshmipathi -
Tool Tip Text for field values in ALV report
Hi,
How to get the tool tip text for the field values in ALV report.
Thanks & Regards,
Pallavi.Hi,
In fieldcatalog specify the TOOLTIP.
<b>
LVC_S_FCAT-TOOLTIP
</b>
In this speicfyteh tooltip you want.
Then append this to the fieldcatalog.
Hope this solves ur problem. -
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®ards.
samba.kHi
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 display multi line headings in procedural alv report
Hi experts,
How to display multi line heading in alv( procedural alv report) report.
some columns single line and some columns multi line in the same report.
ex:
solvent consumed solvent recovered
fresh | recovery recovery | spent batch no storage
I am using procedural alv .pls give me idea.Hi Ram,
Check the sample report [how to display multi line headings in procedural alv report|http://sample-code-abap.blogspot.com/2008/01/printing-multiple-line-header-and.html]
Thanks,
Duy -
Display only first value of the repeated values in ALV report
Hi,
Test Data
Doc No Net Val billing Doc value Qty
1000 2000.00 567850.00
1000 2000.00 567850.00
1000 2000.00 567850.00
2000 6000.00 767850.00
In this type of ALV Report in which only the First field value of the repeated value should be displayed.
Doc No Net Val billing Doc value Qty
1000 2000.00 567850.00
2000 6000.00 767850.00
I can display document value as like expected result in SORT ORDER in LAYOUT but the Quantity value,Net value which cannot be done in SORT ORDER in LAYOUT.
Please tell me the suitable solution.For a Sales Order there are two Invoice.
Sales doc Invoice No Billed Qty Net value Qtywith material no
5000 900 234774.00 456.00000 65 123
234774.00 456.00000 25 456
234774.00 456.00000 35 898
234774.00 456.00000 20 496
901 634774.00 256.00000 50 746
634774.00 256.00000 10 456
634774.00 256.00000 20 545
634774.00 256.00000 30 869
I need to print this billed Qty and Net value only once in first line and it should not be deleted.
I need the result like this
Sales doc Invoice No Billed Qty Net value Qtywith material no
5000 900 234774.00 456.00000 65 123
25 456
35 898
20 496
5001 901 634774.00 256.00000 50 746
10 456
20 545
30 869
The same value should not be repeated for Billed Qty and Net Value.
I can do that for Sales doc in sort order in layout but i couldn't do for Billed qty and Net Value.
Please help. -
Is it possible to display Suffix values in ALV Report
Hi,
Is it possible to display a suffix value in the output of ALV Report? If so how I can proceed? Please let me know an example.
Thanks,
Sekhar.JHi Siddarth,
I am sorry for the typo. It shold be Sub Script, Not a Suffix.
Let us take an example H2O, If we print it in this way it won't be meaning full, So i want to display this like
H Subscript 2 O. I have a requirement for a column to always to display this kind of values, Is it Possible?
Thanks,
Sekhar.J -
Dynamic display of fields of table in ALV report.
To display the records of a table in ALV report dynamically such that first 10 fields of the table should only be displayed excluding 'mandt' field .
That is field no 2nd to 11th should be displayed.parameters: p_vari type slis_vari.
at selection-screen on value-request for p_vari.
perform alv_variant_f4 changing p_vari.
form alv_variant_f4 changing l_vari type slis_vari.
On F4 for layout selection - Get laouts created to this report.
data: l_variant type disvariant.
l_variant-report = sy-repid.
l_variant-username = sy-uname.
call function 'REUSE_ALV_VARIANT_F4'
exporting
is_variant = l_variant
i_save = 'A'
importing
es_variant = l_variant
exceptions
others = 1.
if sy-subrc = 0.
l_vari = l_variant-variant.
endif.
Create a structure
data: wa_layout type disvariant.
fill up the layout with selected fields.
wa_layout-report = sy-repid.
wa_layout-username = sy-uname " Choose this if you want user specific
wa_layout-variant = p_vari.
Assign the same to the REUSE_ALV_GRID_DISPLAY
it is a import paramter IS_VARIANT = wa_layout.
All you have to do is first execute the report and save layouts what exactly you want
and then next time you run the report you will get a chance to select the layout of your own.
or
You can get rid of MANDT field from fieldcatalog and internal table by creating a new
structure. I mean, if you know you always want to display the field from 2 to 11 then simply
delete the field from fieldcatalog.
You can assign to different field catalog using Field symbols and change your internal
table as well since you have created a dynamic internal table.
Let me know if you need more. -
Hi experts,
I have an ALV report.
In the ALV report one of the field is Currency conversion rate to USD.
For this i am fetching value from TCURR-UKURS.
The value is taken into an internal table.
I have seen in the internal table the value is coming correctly. like: suppose the value is 1,114.10000- in that perticulat field. then the same value is coming in my final internal table.
But in the report display it is coming as /1,114.10000
Please help me out
regards,
charlesCheck the field-reference what is your ALV-field pointing at. Maybe this reference is pointing at a field, which enables only positive numbers.
And if you just modified it, don't forget about the ALV-cache, which stores a lot of setting about ALV grids while you are logged in.
To clear ALV cache you can use a transaction (but I forgot it ), or you can log off and relogin to SAP.
Happy developing
Tamá -
Decimal point for Price value in ALV Report
HI,
I have created ALV report,
I have 2 price fields in ALV report
For first field i have to display in the below format.
If the value of the field is 3601152 then I have to display it as 36011.52
For second field I have to display in the below format
if the value is 2494 then I have to display it as 2495.00
else if the value is 3498.73,then I need not to do anything.
that means If there is no decimal point, then I have to keep decimal point.
Thanks&Regards
RamaDeviHI,
you can work with search and concatenate.
value1 = 3601152
search value1 for '.' .
if sy-subrc eq 0.
concatenate value1(5) '.' value1(2)+5 into text.
Or value1 = value1 / 100.
endif.
Regards
Nicole -
Problem with Footer in ALV Report
Hi Experts,
What is coding for Footer In my ALV Report how can I resolve it.
for example will come in footer like this....
'This Report is created by '
Date is ',
'Time is '
Page No ' *
Please find below the piece of codes
REPORT ZALV2 .
TABLES : MAKT. " Material Description
TYPE-POOLS : SLIS.
TYPES : BEGIN OF TY_MAKT,
MATNR TYPE MATNR, " Material No
SPRAS TYPE SPRAS, " Language Key
MAKTX TYPE MAKTX, " Material Description
MAKTG TYPE MAKTG, " Material des in upper case
END OF TY_MAKT.
DATA : T_MAKT TYPE STANDARD TABLE OF TY_MAKT INITIAL SIZE 0,
T_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
T_LISTHEADER TYPE SLIS_T_LISTHEADER.
DATA : W_MAKT TYPE TY_MAKT,
W_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
W_LISTHEADER TYPE SLIS_LISTHEADER,
W_LAYOUT TYPE SLIS_LAYOUT_ALV.
CONSTANTS : C_MATNR TYPE SLIS_FIELDNAME VALUE 'MATNR',
C_SPRAS TYPE SLIS_FIELDNAME VALUE 'SPRAS',
C_MAKTX TYPE SLIS_FIELDNAME VALUE 'MAKTX',
C_MAKTG TYPE SLIS_FIELDNAME VALUE 'MAKTG'.
SELECTION-SCREEN BEGIN OF BLOCK BLK WITH FRAME TITLE TEXT-000.
SELECT-OPTIONS : S_MATNR FOR MAKT-MATNR.
SELECTION-SCREEN END OF BLOCK BLK.
INITIALIZATION.
PERFORM SUB_CLEAR_OBJ.
AT SELECTION-SCREEN. " it is used for validation
PERFORM SUB_VALIDATE_DATA.
START-OF-SELECTION.
PERFORM SUB_FETCH_DATA.
PERFORM SUB_FIELDCAT USING :
C_MATNR TEXT-001 'X',
C_SPRAS TEXT-002 ' ',
C_MAKTX TEXT-003 ' ',
C_MAKTG TEXT-004 ' '.
PERFORM SUB_LAYOUT.
PERFORM SUB_DISPLAY.
END-OF-SELECTION.
TOP-OF-PAGE.
PERFORM SUB_TOP_OF_PAGE.
PERFORM SUB_WRITE_HEADER.
END-OF-PAGE.
PERFORM SUB_SET_PF_STATUS.
*& Form SUB_CLEAR_OBJ
text
--> p1 text
<-- p2 text
FORM SUB_CLEAR_OBJ .
REFRESH : T_MAKT,
T_FIELDCAT,
T_LISTHEADER.
CLEAR : W_MAKT,
W_FIELDCAT,
W_LISTHEADER.
ENDFORM. " SUB_CLEAR_OBJ
*& Form SUB_VALIDATE_DATA
text
--> p1 text
<-- p2 text
FORM SUB_VALIDATE_DATA .
DATA : L_MATNR TYPE MATNR.
SELECT MATNR UP TO 1 ROWS FROM MAKT INTO L_MATNR. " IN S_MATNR.
ENDSELECT.
IF SY-SUBRC <> 0.
MESSAGE E000(15) WITH 'IT IS AN INVALID NUMBER'.
ENDIF.
ENDFORM. " SUB_VALIDATE_DATA
*& Form SUB_FETCH_DATA
text
--> p1 text
<-- p2 text
FORM SUB_FETCH_DATA .
SELECT MATNR SPRAS MAKTX MAKTG FROM MAKT INTO TABLE T_MAKT WHERE MATNR
IN S_MATNR.
ENDFORM. " SUB_FETCH_DATA
*& Form SUB_FIELDCAT
text
-->P_C_MATNR text
-->P_TEXT_001 text
-->P_0122 text
-->P_0123 text
FORM SUB_FIELDCAT USING :
FLD TYPE SLIS_FIELDNAME
TXT TYPE SCRTEXT_L
COL TYPE SLIS_FIELDCAT_ALV-OPTIMIZE
HPOT TYPE C.
W_FIELDCAT-TABNAME = 'ZSHEREE2'.
W_FIELDCAT-FIELDNAME = FLD.
W_FIELDCAT-SELTEXT_M = TXT.
*W_FIELDCAT-EMPHASIZE = COL.
W_FIELDCAT-HOTSPOT = HPOT.
APPEND W_FIELDCAT TO T_FIELDCAT.
ENDFORM. " SUB_FIELDCAT
*& Form SUB_LAYOUT
text
--> p1 text
<-- p2 text
FORM SUB_LAYOUT .
W_LAYOUT-COLWIDTH_OPTIMIZE = 'X'.
W_LAYOUT-ZEBRA = 'X'.
W_LAYOUT-F2CODE = '&ETA'.
ENDFORM. " SUB_LAYOUT
*& Form SUB_DISPLAY
text
--> p1 text
<-- p2 text
FORM SUB_DISPLAY .
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
I_CALLBACK_PROGRAM = 'ZSHEREE2 '
I_CALLBACK_PF_STATUS_SET = 'PF_STATUS_SET '
I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = 'SUB_TOP_OF_PAGE '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = 'ALV_BACKGROUND '
I_GRID_TITLE = 'Header Item / Data'
I_GRID_SETTINGS = 5
IS_LAYOUT = W_LAYOUT
IT_FIELDCAT = T_FIELDCAT
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 =
I_SCREEN_START_LINE =
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 = T_MAKT
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. " SUB_DISPLAY
*& Form SUB_TOP_OF_PAGE
text
--> p1 text
<-- p2 text
FORM SUB_TOP_OF_PAGE .
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = T_LISTHEADER
I_LOGO =
I_END_OF_LIST_GRID =
REFRESH T_LISTHEADER.
ENDFORM. " SUB_TOP_OF_PAGE
*& Form SUB_WRITE_HEADER
text
--> p1 text
<-- p2 text
FORM SUB_WRITE_HEADER .
W_LISTHEADER-TYP = 'H'.
W_LISTHEADER-INFO = 'PLANT WISE DATA DISPLAYED'.
APPEND W_LISTHEADER TO T_LISTHEADER.
ENDFORM. " SUB_WRITE_HEADER
*& Form SUB_SET_PF_STATUS
text
--> p1 text
<-- p2 text
FORM PF_STATUS_SET USING
RT_EXTAB TYPE SLIS_T_EXTAB.
SET PF-STATUS 'ZSTATUS1'.
ENDFORM. " SUB_SET_PF_STATUS
If any mistake where i am wrong sorry for that.You create one subroutine for END-OF-PAGE. Call this in the FM,
REUSE_ALV_EVENTS_GET.
Example:
Data: i_event TYPE slis_t_event.
*& Form f_build_eventtab
text
FORM f_build_eventtab USING ps_event TYPE slis_t_event.
DATA: wa_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = ps_event.
READ TABLE ps_event WITH KEY name = slis_ev_end_of_page INTO wa_event.
IF sy-subrc EQ c_0.
MOVE slis_ev_end_of_page TO wa_event-form.
APPEND wa_event TO ps_event.
ENDIF.
ENDFORM. " f_build_eventtab
*& Form END OF PAGE *
*& To display the footer details *
FORM end_of_page .
Write the footer details
ENDFORM. "END_OF_PAGE
I hope this will be useful for you.
Regards,
Joan -
How to Input Value in ALV report at reuntime...?
Dear All,
How to Input Value or change the value of a field in ALV report at runtime...?
regards,HI,
To input value in ALV you have to make it editable.
to change values at runtime you have to capture some events and then change your values in internal table which is used to display alv.
Here is an example of editable ALV.
<b>REPORT ZWA_ALV_EDITABLE_FM .
type-pools: slis.
data: gs_layout type slis_layout_alv.
DATA: d_ref TYPE REF TO data.
DATA: itab type table of fmfint.
SELECT * FROM fmfint
INTO TABLE itab.
gs_layout-edit = 'X'.
* Call ABAP List Viewer (ALV)
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = 'ZWA_ALV_EDITABLE_FM'
i_callback_user_command = 'USER_COMMAND'
i_structure_name = 'fmfint'
is_layout = gs_layout
tables
t_outtab = itab.
form user_command using r_ucomm type sy-ucomm
rs_selfield type slis_selfield.
if r_ucomm = '&DATA_SAVE'.
message i000(SU) with 'saved'.
MODIFY fmfint FROM TABLE itab.
call function 'REUSE_ALV_LIST_DISPLAY'
exporting
i_structure_name = 'fmfint'
tables
t_outtab = itab.
endif.
endform.</b>
Regards,
Wasim Ahmed -
Display Color for sigle CELL in ALV report
Hi all,
I have one doubt is it possible to make a particular cell as read color in ALV.
Ex: I have one field which shows amount in my ALV report,My requirement is that when ever the amount is less then 'ZERO', I have to show that particular cell in read color.
Regards
Anil Kumar.Nhi,
here code for coloring a perticular cell
TYPE-POOLS:slis.
TABLES:mara,
makt,
marc.
DATA:BEGIN OF itab OCCURS 0,
matnr LIKE mara-matnr,
maktx LIKE makt-maktx,
werks LIKE marc-werks,
mtart LIKE mara-mtart,
matkl LIKE mara-matkl,
meins LIKE mara-meins,
ntgew LIKE mara-ntgew,
rowcolor(4) TYPE c,
cellcolors TYPE lvc_t_scol,
END OF itab.
DATA:t_fcat TYPE slis_t_fieldcat_alv,
t_eve TYPE slis_t_event.
DATA : st_layout TYPE slis_layout_alv.
SELECTION-SCREEN:BEGIN OF BLOCK blk1 WITH FRAME TITLE text-001.
SELECT-OPTIONS:mat FOR mara-matnr. " no intervals no-extension.
*PARAMETERS:mat LIKE mara-matnr.
SELECTION-SCREEN:END OF BLOCK blk1.
INITIALIZATION.
PERFORM build_cata USING t_fcat.
PERFORM build_event.
START-OF-SELECTION.
PERFORM data_retrieval.
PERFORM display_data.
*& Form build_cata
text
-->TEMP_FCAT text
FORM build_cata USING temp_fcat TYPE slis_t_fieldcat_alv.
sy-tvar0 = sy-uname.
WRITE sy-datum TO sy-tvar1.
DATA:wa_fcat TYPE slis_fieldcat_alv.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'MATNR'.
wa_fcat-seltext_m = 'Material'.
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'MAKTX'.
wa_fcat-seltext_m = 'Description'.
wa_fcat-fix_column = 'x'.
wa_fcat-key = 'X'. "To color a column
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'WERKS'.
wa_fcat-seltext_m = 'Plant'.
wa_fcat-key = ' '.
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'MTART'.
wa_fcat-seltext_m = 'Type'.
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'MATKL'.
wa_fcat-seltext_m = 'Group'.
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'MEINS'.
wa_fcat-seltext_m = 'Measurement Unit'.
APPEND wa_fcat TO temp_fcat.
wa_fcat-tabname = 'ITAB'.
wa_fcat-fieldname = 'NTGEW'.
wa_fcat-seltext_m = 'Net Value'.
APPEND wa_fcat TO temp_fcat.
ENDFORM. "build_cata
*& Form build_event
text
FORM build_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = t_eve
EXCEPTIONS
list_type_wrong = 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. "build_event
*& Form data_retrieval
text
FORM data_retrieval.
SELECT maramatnr maramtart maramatkl marameins mara~ntgew
maktmaktx marcwerks
INTO CORRESPONDING FIELDS OF TABLE itab
FROM mara INNER JOIN makt ON
maramatnr = maktmatnr
INNER JOIN marc ON
maramatnr = marcmatnr
WHERE mara~matnr IN mat.
SORT itab BY matnr.
DELETE ADJACENT DUPLICATES FROM itab.
ENDFORM. "data_retrieval
*& Form display_data
text
FORM display_data.
*******************************For setting Cell Color*******************************************
DATA ls_cellcolor TYPE lvc_s_scol .
st_layout-coltab_fieldname = 'CELLCOLORS'.
READ TABLE itab INDEX 5 .
ls_cellcolor-fname = 'MATNR' .
ls_cellcolor-color-col = '1' .
ls_cellcolor-color-int = '1' .
APPEND ls_cellcolor TO itab-cellcolors .
MODIFY itab INDEX 5 .
st_layout-colwidth_optimize = 'X'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = 'ZALV_DS'
is_layout = st_layout
i_save = 'A'
it_fieldcat = t_fcat
it_events = t_eve
TABLES
t_outtab = itab
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. "display_data
Please reward if useful...
Maybe you are looking for
-
Sharing Music (From a 'Windows 7' Computer to an iPod Touch)
Folks, I need some help! I'm not a big user of Apple Products - just getting started and still not sure about the technology/terminology so please forgive me if I use the wrong words! My friend has an iPod Touch (4th Generation). It's linked to her i
-
After upgrading to Snow Leopard no internet connection anymore
First of all thanks to all of you trying to help others with Mac related issues. Now I have an issue: I just upgraded my iMac from Leopard 10.5.8 to Snow Leopard. The iMac is a lot faster now BUT ....... I have no connection to internet anymore. Safa
-
Problem with iChat over wireless network
iChat with AIM account has always worked fine, but from the moment I installed a netgear router over a wireless network it enters a loop of disconnection/connection until I get the message "you have been connecting and disconneting too frequently". S
-
My clock is changing after every start of OSX Or WINXP. What is it?
I had a problem in the beginning with my iMac: It didn't shut down correctly and made weird thinks. I brought is to the Apple Centre and they said that could be a hardware problem. After the inspection they said that every part is OK. Then I had to p
-
Problem to run a CATT to replace accounting clerk data
Hi, I have created a CATT in the development system to modify accounting clerk data in the production system. When I do a remote execution (production system) in the background, I see errors in the log. "No batch input data for screen SAPMF02D 7101.