• Home
  • About me
  • FALV
  • ALV Grid in the nutshell
    • Basic Information
    • Field catalog
  • Articles
    • Tricks
    • FALV (Fast ALV Grid)
    • ALV Grid in the nutshell
    • Tips
    • How to...
    • For beginners
    • Thoughts
  • By Topic
    • ALV
    • ALV OO
    • SALV
    • GOS
    • Selection screen
    • Purchase Requisitions
    • Purchase Orders
    • Attachments
    • Others
    • Characteristics
    • Sample Programs
    • ZIP
    • OLE
    • Mails
    • Routings
    • EWB
    • Excel
  • Keywords
  • RSS
  • Download
  • Home

ALV Grid in the nutshell: Field catalog - col_id - ALV control: Column ID

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 08 June 2020
Hits: 920
5 1 1 1 1 1 Rating 100% (1 Vote)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , COL_ID , ALV GRID

Column ID is not really a special field in ALV. It is always filled automatically by ALV and your manual entries are overwritten and set to the same value as COL_POS (Column position).

I’ve prepared a demo program (ZDEMO_AIN_CL46) to show you, how the COL_ID is changing on a base of COL_POS. On the selection screen you can find two radio-buttons.
 

Figure 120 ZDEMO_AIN_CL46 Selection screen

 

When you select the first option - “COL_ID filled”,  the FCAT will be created with manual COL_ID.
 

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - dfieldname – Fieldname for column group

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 27 April 2020
Hits: 995
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , DFIELDNANE , ALV GRID

I was trying to find an usage of this field in ALV, but I failed. Any of known behaviours of ALV didn’t shown anything on a base of this field.

 

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - Hotspot - ALV control: SingleClick-sensitive

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 27 April 2020
Hits: 1618
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , HOTSPOT , ALV GRID

Hotspot fields are very widely used in ALV, such fields have the behaviour and style of hyperlinks, which means they are triggering the single-click event of ALV called HOTSPOT_CLICK. It is commonly used to show the details of the clicked object, or to move to a transaction in which the object can be modified.

As you can imagine, setting column as a HOTSPOT is very easy, you need to pass only the ABAP_TRUE (‘X’) value to the field catalog, but this will only change the style of the field (content of the field is underlined) and it will fire the HOTSPOT_CLICK event.

Figure 114 Setting column as hotspot

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - sp_group - Group key

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 18 April 2020
Hits: 1230
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , SP_GROUP , ALV GRID

Group key is not widely used but it has nice feature. Once you group the field catalog fields and you pass the group name into parameter IT_SPECIAL_GROUPS of method SET_TABLE_FOR_FIRST_DISPLAY, then in selection of fields to display in layout change window, you’ll be able to choose to see all hidden fields or the hidden fields from the group you’ve created. If you don’t pass the group name into IT_SPECIAL_GROUPS, then this setting of field catalog has no impact on display.

 

For my demo program ZDEMO_AIN_CL43, I’ve created a field catalog with REF_TABLE filled for all fields, so it is easier to understand the functionality. Additionally, I’ve hidden all fields that have SP_GROUP filled, so you can check the behaviour directly after running the program.

 

Figure 109 Field catalog with Group Keys

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - domname - Domain name

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 18 April 2020
Hits: 600
4 1 1 1 1 1 Rating 80% (1 Vote)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , DOMNAME , ALV GRID

You may suspect that setting up a domain name in the field catalog will make some effect on the display, for example in data type, length, lowercase sign,  but it seems that it has no effect in ALV grid. Maybe just for information and for Report-Report interface, where this field is use as one of the matching criteria for selection-screen parameters.

As you can see on the next image, although I gave the DOMNAME value FLAG, it didn’t changed anything in the field catalog.

 

Figure 108 DOMNAME in Field catalog

Add a comment

ALV Grid in the nutshell: Field catalog - reprep - ALV control: Value is selection criterion for rep./rep.intf.

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 13 April 2020
Hits: 897
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , REPREP , ALV GRID

Before writing this part, I was never using Report-Report Interface, so probably it is not common scenario to do so, or it is not used with the systems I had possibility to use. But anyway I’ve made a deep dive into topic, to understand how we can use this interface and for which purpose.  

Seems that, using this interface, you can call from ALV grid an BW Query, SAP Query, ABAP Report Program or Transaction. Probably depending on the installed version of your system, or addons, the list of the interfaces may be longer.

Anyway I’ve focused here on a simple example of calling another ABAP report using RRI. At the beginning I was wondering if configuration in table TRSTI and setting the parameter REPREP to ABAP_TRUE will be enough to call the interface. So I’ve started with filling TRSTI, where I’ve set sender and receiver, both as RT (ABAP Report Program).

Figure 100 TRSTI entry for sender program

 

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - reptext – Heading

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 13 April 2020
Hits: 943
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , REPTEXT , ALV GRID

This field allows us to set (or change) the header text of the column. It can consist up to 55 characters in lowercase mode. When you use data dictionary reference ( REF_FIELD, REF_TABLE ) it is populated automatically from the data element of the referenced field.

Figure 97 Texts of Data Element S_FROMAIRP

 

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - lowercase - Lowercase letters allowed/not allowed

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 13 April 2020
Hits: 830
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , LOWERCASE , ALV GRID

The changes of this parameter are only visible in edit mode and makes sense only for character or string fields. If it is set to ABAP_TRUE (‘X’), then the ALV grid stores in internal table the value in lowercase, if the value of the parameter is empty, then it will always convert the entered value to uppercase.

 

Figure 96 Results of zdemo_ain_cl39 with lowercase turned on

 

 

Add a comment

ALV Grid in the nutshell: Field catalog - intlen - Internal Length in Bytes

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 13 April 2020
Hits: 618
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , INTLEN , ALV GRID

As the description says, the meaning of that field is to set the internal length of the field in Bytes. During my whole career as ABAP Developer, I had never filled that field manually. Usually you’ll not bother yourself about it. But if you do, then take into consideration following information:

  • Length is in Bytes, so remember that it doesn’t mean, that one character takes one Byte
  • In display mode, you’ll not notice probably any change
  • When you’ll setup this incorrectly, you may have problems when you allow grid to be editable, for example:
    When I’ve set the INTLEN to ‘2’ for column FLTIME, then although I’ve entered the value of ‘12’ into the column, system didn’t allowed me to save it.

 

Figure 94 Error in edit mode caused by wrong value of field INTLEN (ZDEMO_AIN_CL38)

 


Figure 95 Error message of  ZDEMO_AIN_CL38

 

 

Add a comment

Downloading Exchange Rates from NBP (National Bank of Poland)

Details
Written by Łukasz Pęgiel
Category: How to...
Published: 06 April 2020
Hits: 932
1 1 1 1 1 Rating 0% (0 Votes)
Tags: BAPI_EXCHANGERATE_CREATE , CL_HTTP_CLIENT , CALL TRANSFORMATION

Following the example of downloading exchange rates from Central Bank Of Turkey using transformations, please find bellow the same way for National Bank of Poland.

Again, lets create an RFC destination (lets call it here Z_DESTINATION_TO_NBP) tha will point to https://www.nbp.pl/kursy/xml/lasta.xml, where the last exchange rates are posted.

Add a comment
Read more ...

Downloading Exchange Rates from Central Bank of Turkey

Details
Written by Łukasz Pęgiel
Category: How to...
Published: 06 April 2020
Hits: 1280
1 1 1 1 1 Rating 0% (0 Votes)
Tags: BAPI_EXCHANGERATE_CREATE , CL_HTTP_CLIENT , CALL TRANSFORMATION

One of the standard requests that comes with every SAP implementation is automatic download of exchange rates to your system. Today I will show you on an example of Central Bank Of Turkey, how to transform XML from bank site into internal table, which can be then used inside your code to populate values of  BAPI_EXCHANGERATE_CREATE FM.

There are few ways to download the XML to your ABAP code, I prefer to create an RFC destination (lets call it here Z_DESTINATION_TO_TCMB), as on many servers you need to provide credentials for PROXY and it is safer to keep it saved inside RFC destination, than in your ABAP code in plain text.

So lets assume you have an RFC destination that points to https://tcmb.gov.tr/kurlar/today.xml. It will look like this:

Add a comment
Read more ...

ABAP Extensions - Automatic Logon

Details
Written by Łukasz Pęgiel
Category: How to...
Published: 04 January 2020
Hits: 3036
5 1 1 1 1 1 Rating 100% (6 Votes)
Tags: ECLIPSE , ADT , PLUGIN , ABAP EXTENSIONS , AUTOMATIC LOGON

Yesterday I've announced that I'm working on automatic logon to SAP systems on Eclipse. Today the changes in the plugin ABAP Extensions for Eclipse are published and you can use the first version of the automatic logon on your installations.

 

ABAP Extensions plugin you can find in Eclipse Marketplace or by doing direct installation from this link http://abapblog.com/eclipse/plugin/ABAPFavorites/ or by using the install button which you can find on the right side of this page.

 

After installation of update will be able to set the preference if you want to do automatic logon at start of Eclipse and if you want to logon automatically only to the systems, for which you have stored the password already. These are also default settings for the plugin. The logon happens in the background job. So if you have several systems in your workspace, it will take a while to logon to all the systems. The progress you can follow in the Progress View.

 

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - inttype - ABAP data type (C,D,N,...)

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 18 December 2019
Hits: 1605
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , INTTYPE , ALV GRID

As you can imagine, INTTYPE is just a presentation of DATATYPE in internal SAP format in most of cases. I wrote most of cases because it can also say if the field in internal table is a reference to other type, or for example a table.

Just like DATATYPE, you don’t need to fill this field manually, when you’ll leave it empty, ALV grid will automatically setup a proper type according to referenced internal table field. But if you’ll have unstoppable need of filling it, then the behaviour of the column will be exactly the same like you would use DATATYPE field, means JUST, OUTPUTLEN, INTTYPE, INTLEN and DD_OUTLEN fields will be also field and the difference on the screen will be not that huge.

 

Figure 93 Fieldcatalog of the ZDEMO_AIN_CL37 for Internal ABAP type T

Add a comment
Read more ...

ALV Grid in the nutshell: Field catalog - datatype

Details
Written by Łukasz Pęgiel
Category: ALV Grid in the nutshell
Published: 11 December 2019
Hits: 1442
1 1 1 1 1 Rating 0% (0 Votes)
Tags: CL_GUI_ALV_GRID , ALV GRID IN THE NUTSHELL , FIELDCATALOG , LVC_T_FCAT , DATATYPE , ALV GRID

DATATYPE field has small influence on the way the column is displayed. You can omit this field and then ALV grid will automatically fill this field and additionally JUST, OUTPUTLEN, INTTYPE, INTLEN and DD_OUTLEN on a base of the type of the output table field.  

But if you decide to fill it, then on a base of DATATYPE you’ll notice different justification or output length. But still all checks of the data entered in edit mode will be done on a base of the real data type of the linked internal table field.

Possible data types form system NW 7.52 SP04 can be found bellow.

Data Type

Short Description

ACCP

Posting Period YYYYMM

CHAR

Character String

CLNT

Client

CUKY

Currency Key for Currency Field

CURR

Currency Field in BCD Format

DF16_DEC

Decimal Floating Point Stored in BCD Format

DF16_RAW

Decimal Floating Point Stored as Binary Number

DF16_SCL

Decimal Floating Point with Scaling (obsolete)

DF34_DEC

Decimal Floating Point Stored in BCD Format

DF34_RAW

Decimal Floating Point Stored as Binary Number

DF34_SCL

Decimal Floating Point with Scaling (obsolete)

DATS

Date in Format YYYYMMDD

DEC

Packed Number in BCD Format

FLTP

Floating Point Number

INT1

1-Byte Integer, 0 to 255

INT2

2-Byte Integer, -32.768 to 32.767

INT4

4-Byte Integer, -2.147.483.648 to +2.147.483.647

INT8

8-Byte Integer

LANG

Language key

LCHR

Long Character String

LRAW

Long Byte String

NUMC

Numerical Text

PREC

Obsolete Data Type

QUAN

Quantity Field in BCD Format

RAW

Byte Sequence

RAWSTRING

Byte String (BLOB)

SSTRING

Character String

STRING

Character String (CLOB)

TIMS

Time in Format HHMMSS

UNIT

Unit Key of Quantity Field

VARC

Obsolete Data Type

Table 2 Possible data types in NW 7.52 SP04

Add a comment
Read more ...

More Articles ...

  1. ALV Grid in the nutshell: Field catalog - rollname
  2. ALV Grid in the nutshell: Field catalog - tooltip
  3. ALV Grid in the nutshell: Field catalog - seltext
  4. ALV Grid in the nutshell: Field catalog - convexit
  5. ALV Grid in the nutshell: Field catalog - tech
  6. ALV Grid in the nutshell: Field catalog - no_out
  7. ALV Grid in the nutshell: Field catalog - no_sum
  8. ALV Grid in the nutshell: Field catalog - do_sum
  9. ALV Grid in the nutshell: Field catalog - fix_column
  10. ALV Grid in the nutshell: Field catalog - emphasize
Page 1 of 11
  • Start
  • Prev
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • Next
  • End
Łukasz Pęgiel
KKEK CONVERT FLOAT CURR FILL MDPA FROM EBAN SBCS SEND UPDATE ALV GRID REFRESH SELECTOPTIONS MEREQ GET FACTORY MB51 ALV GRID FRIEND GUI PROCESS CUST ALV Grid in the nutshell Field catalog - exponent LVC FCAT Copy routing create on a base of existing one EWB Components allocation to routing operation multilevel BOM RESET REJ ALLOWED SAPGUI PROGRESS INDICATOR DELETE USER OBJECTS SALV TABLE FIELDCATALOG ESRUO ALV GRID IN THE NUTSHELL FIELDNAME Field catalog - do sum Field catalog - reptext Heading UI2 JSON CALL TRANSFORMATION F4IF START VALUE REQUEST Field catalog - sp group - Group key FALV Creating editor for dynamic code SE38 like SCMS XSTRING BINARY MTK SAP TechEd 2016 SET FUNCTIONCODE CONVEXIT REL ABAP HTML CVIC MAP CONTACT VIRTUALBOX BOM DARK THEME MS07 SETTINGS Classifications - Part 2 - Get Object Details Custom selection-screen fields for MD07 EXTEND PROGRAM RUNTIME #SAPTechEd 2016 Barcelona COC1 FEATURE CHECK ABAP DEVELOPMENT TOOLS IN ECLIPSE Field catalog - tabname PURCHASE REQUISITION GOS MANAGER ABAP FAVORITES PROVIDE COM OPR Save message with attachment in Outlook's Drafts Field catalog - dfieldname
  • Laserowe usuwanie blizn Tychy
  • Laserowe usuwanie zmarszczek Tychy
  • Paznokcie hybrydowe Tychy
  • Paznokcie tytanowe Tychy
  • Salon Kosmetyczny Tychy
  • Trycholog Tychy
  • Wypadanie włosów Tychy
Tweets by abapblog

Eclipse Plugins for ABAP

ABAP Favorites

Drag to your running Eclipse* workspace. *Requires Eclipse Marketplace Client

ABAP ADT Extensions

Drag to your running Eclipse* workspace. *Requires Eclipse Marketplace Client

ABAP Quick Fixes

Drag to your running Eclipse* workspace. *Requires Eclipse Marketplace Client

 

Latest Articles

  • ALV Grid in the nutshell: Field catalog - col_id - ALV control: Column ID
  • ALV Grid in the nutshell: Field catalog - dfieldname – Fieldname for column group
  • ALV Grid in the nutshell: Field catalog - Hotspot - ALV control: SingleClick-sensitive
  • ALV Grid in the nutshell: Field catalog - sp_group - Group key
  • ALV Grid in the nutshell: Field catalog - domname - Domain name
  • ALV Grid in the nutshell: Field catalog - reprep - ALV control: Value is selection criterion for rep./rep.intf.
  • ALV Grid in the nutshell: Field catalog - reptext – Heading
  • ALV Grid in the nutshell: Field catalog - lowercase - Lowercase letters allowed/not allowed
  • ALV Grid in the nutshell: Field catalog - intlen - Internal Length in Bytes
  • Downloading Exchange Rates from NBP (National Bank of Poland)
  • Downloading Exchange Rates from Central Bank of Turkey
  • ABAP Extensions - Automatic Logon
  • ALV Grid in the nutshell: Field catalog - inttype - ABAP data type (C,D,N,...)
  • ALV Grid in the nutshell: Field catalog - datatype
  • ALV Grid in the nutshell: Field catalog - rollname

Most Read

  • Create XLSX/MHTML file from internal table in background
  • Refresh ALV GRID and keep position and current cell
  • Call standard F4 search help with customized parameters
  • FALV (Fast ALV Grid)
  • Dynamic GUI STATUS & TITLE with ABAP code
  • Create a nice looking chart with CL_GUI_CHART_ENGINE - Part 3 - Chart Data and render
  • Link Attachments of Purchase Requisition to Purchase Order
  • GOS - How to add business documents at creation of object
  • Subtotal lines of ALV GRID OO as content separator
  • Create fieldcatalog from internal table
  • Endless loop in BADI ME_PROCESS_PO_CUST
  • EWB Components allocation to routing operation (multilevel BOM)
  • Save message with attachment in Outlook's Drafts
  • How to access private or protected data and methods of CL_GUI_ALV_GRID
  • Popup with multi-select ALV
feed-image Feed Entries

Latest Comments

ABAP code and articles provided on http://abapblog.com, if it is not statet otherwise, were created by Łukasz Pęgiel. You can use the code in your SAP instance for commercial and non-commercial use without any warranty from side of the author. You cannot sell the code as a full program or a part of it.
Replicating of the articles and code is prohibited unless the agreement of the author is given to you.