SE24ABAP

SAP SE24Class Builder

Modern ABAP is written with classes. A class bundles data (attributes) and the operations on that data (methods) into one named unit, and hides the internals behind a defined public surface. If you have met object-oriented programming anywhere else, this is the same idea with ABAP syntax.

ABAP distinguishes local classes, defined inside a single program and usable only there, from global classes, stored centrally and usable by anything in the system. SE24 is the tool for global ones. Standard SAP global classes are named CL_something; interfaces are IF_something; exception classes are CX_something; custom ones start with ZCL_, ZIF_ and ZCX_.

The reason SE24 is useful to people who do not write ABAP is the same as SE37’s: it can run things. Press the test button and you get a screen that lets you instantiate the class, call a method with input values you type in, and see what comes back. That is a real diagnostic tool, not just a code viewer.

One concept to have straight before you use it. Each component is either instance level, meaning it belongs to one object you create, or static level, meaning it belongs to the class itself and needs no object. A static method can be called directly; an instance method needs an object first, and whether you are allowed to create one depends on the class’s instantiation setting.

When you would actually use SE24

What the screen looks like

Class Builder: Initial Screen
SE24
Object typeCL_ABAP_TSTMP
Display reads the class. Change requires a development system and, for SAP standard classes, an access key.
Client 100 | S/4HANA | Company Code 1000
Illustrative recreation.One field: the class or interface name — Drawn for training with invented data; not a capture of a real SAP system. Fields with a blue border are required. SAP is a trademark of SAP SE.
Class Builder: Display Class ZCL_ORDER_VALIDATOR
SE24
PropertiesInterfacesFriendsAttributesMethodsEventsTypes
MethodLevelVisibilityDescription
CONSTRUCTORInstancePublicCreate validator for one plant
GET_INSTANCEStaticPublicFactory - returns the singleton
VALIDATE_ORDERInstancePublicCheck one order and return messages
READ_CONFIGInstancePrivateLoad validation rules from customising
Instantiation: private — objects can only be created through GET_INSTANCE.
Client 100 | S/4HANA | Company Code 1000
Illustrative recreation.Level and visibility together tell you how a class is meant to be used — Drawn for training with invented data; not a capture of a real SAP system. Fields with a blue border are required. SAP is a trademark of SAP SE.

The fields, in plain English

Object type

The class or interface name. CL_ and IF_ prefixes are SAP standard, CX_ marks an exception class, and ZCL_, ZIF_, ZCX_ mark custom ones written at your organisation.

Watch out: A Z prefix means somebody local wrote it. Do not assume it is documented, tested, or that it behaves like the standard class it resembles.

Visibility

Public components can be used by anything. Protected components are available to the class and anything that inherits from it. Private components are available only inside the class. The public list is the contract; everything else is implementation detail that can change.

Watch out: Building against a protected or private component is not possible, and building against an undocumented public one in a standard SAP class is only slightly safer.

Level (instance or static)

Instance components belong to an object you create. Static components belong to the class and can be called without creating anything. A static method is the easiest thing in SE24 to test, because there is no object to construct first.

Instantiation

On the Properties tab. Public instantiation means anyone can create an object. Private means only the class itself can, which is the pattern behind factory and singleton designs — you call a static method such as GET_INSTANCE instead.

Watch out: This is why the test environment sometimes refuses to create an object. It is the class design working as intended, not a fault.

Interfaces

A list of method signatures with no implementation, which a class promises to provide. Interfaces are how ABAP lets unrelated classes be used interchangeably, and how most SAP extension points are defined.

Exceptions

Class-based exceptions, named CX_something, are how modern ABAP reports failure. A method’s signature lists the exceptions it can raise, and reading them tells you how it fails — usually more informative than reading how it succeeds.

Step by step

  1. 1Enter the class or interface name and press Display.
  2. 2Read the Properties tab first — superclass, instantiation, whether the class is final or abstract.
  3. 3Read the Methods tab, noting level and visibility on each row.
  4. 4Double-click a method to see its parameters and its exceptions.
  5. 5Press the test button to open the test environment.
  6. 6For a static method, call it directly. For an instance method, create an object first — or call the factory method if instantiation is private.
  7. 7Read the returned parameters and any exception that was raised.

Errors you will hit, and what they mean

Class ZCL_ORDER_VALIDATOR does not exist

Why: Typo, or the class exists only in the development system and has not been transported here.

Fix: Search with a wildcard on the object type field. If it exists in development and not here, chase the transport rather than the name.

The class is inactive

Why: Someone changed it and never activated it. Normal in a development system, and a problem anywhere else.

Fix: Leave it alone unless it is your change. An inactive class is somebody’s work in progress and activating it publishes their unfinished work.

Object can only be changed with an access key

Why: You are trying to modify an SAP standard class.

Fix: Almost never the right answer. Look for an interface, an enhancement point or a BAdI intended for the purpose. A modified standard class is a permanent upgrade cost.

The test environment will not let me create an object

Why: Instantiation is private or protected, or the class is abstract and cannot be instantiated at all.

Fix: Use the static factory method the class provides, usually named GET_INSTANCE or CREATE. If the class is abstract, test a concrete subclass instead.

Common questions

What is the difference between SE24 and SE80?

SE80 is the Object Navigator — one workbench covering programs, function groups, classes, Dictionary objects and packages in a single tree, and it includes everything SE24 does. SE24 goes straight to one class in fewer clicks. Developers working across objects live in SE80; someone looking up one class opens SE24.

What is the difference between a class method and a function module?

Both are reusable blocks of ABAP with a defined interface. Function modules (SE37) are the older procedural mechanism and are grouped into function groups. Class methods are grouped into classes with visibility, inheritance and interfaces, and are what new development uses. Function modules are still everywhere, and RFC calls from outside SAP still need them.

Can I read the code of standard SAP classes?

Yes. Display mode shows the source of every method, and reading it is often the fastest way to establish what a standard class really does when the documentation is thin.

Transactions that go with SE24

Reading about it only gets you so far

Practise SAP transactions in a safe simulated environment and keep what you learn.

Practise SAP transactions hands-on

Interactive modules, games, and an AI tutor — free to start.

Get started free →