Commu
nity
Products and TechnologyGroupsPartnersEventsHelp CenterTopic PagesExplore SAP
SAP Community/ Products and Technology/ Enterprise Resource Planning/ ERP Blog Posts by SAP/ Add a validation to a Custom Field via Developer E...
Enterprise Resource Planning Blog Posts by SAP
Search
Add a validation to a Custom Field via Developer
Extensibility in SAP S/4HANA Cloud
PrasanthPadmanabhan
Product and Topic Expert
2022 Sep 211:42 PM
5 Kudos
3,385
SAP MANAGED TAGS
SAP S/4HANA Cloud Public Edition Extensibility SAP S/4HANA Cloud ABAP EnvironmentABAP Development
ABAP Extensibility SAP S/4HANA Cloud Public Edition
Introduction
Related Content
A Practical Guide to Cost Center APIs in
SAP S/4HANA Cloud
in Enterprise Resource Planning Blog Posts
by SAP10 hours ago
From Backlogs to Breakthroughs: What
ABAP AI Means for Project Delivery
in Enterprise Resource Planning Blog Posts
by SAPWednesday
My Learning Journal on BTP (5) - Build A
Small Finance Agent: CAP + Generative AI
Hub + LangChain
in Enterprise Resource Planning Blog Posts
by SAPa week ago
Blog
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 1/16
With the introduction of Three System Landscape(3SL) in SAP S/4HANA Cloud, developers
will now be able to create development projects via Eclipse IDE with the help of ABAP
Development Tools (ADT)
In this blog, I will take you through a simple example of how to add a screen validation to a
Custom field created via Key-User Extensibility in the Development 100 client using
Developer Extensibility in the Development 080 client
Implementation
Let’s take the example of the custom field ‘Enhancement Field 1’ which was created via Key-
User Extensibility in the Development 100 system
Now, create a BAdI implementation in the Development 080 client to add a validation such
that the Sales Order should not be saved if this field is empty.
As shown in the following screenshot, after logging into the Development 080 Client, I have
derived a new tree for Application Components.
Localization in SAP S/4HANA: Strategic
Enabler or Deployment Bottleneck?
in Enterprise Resource Planning Blog Posts
by SAP2 weeks ago
SAP Fiori development newsletter
September2025 (issue #36)
in Enterprise Resource Planning Blog Posts
by SAP2 weeks ago
Top Kudoed Authors
GregoireDesombre 8
murthy_v 7
Tiffany_L 6
George_Yu1 5
AlexanderRother 5
Thanuja 4
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 2/16
By deriving this tree, it will be easier for me to search and identify the enhancement spot I am
looking for.
Now that the enhancement spot, ES_SD_SLS_EXTEND, is identified, right click on the
enhancement spot and click on ‘New BAdI Enhancement Implementation’ to create a new
Enhancement Implementation.
View all
Jocelyn_Dart 4
Raphael_Caillon 4
GertTackaert 4
SHRUTHISADAGOPA
NPITCHUMANI
3
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 3/16
Provide a Package name, Enhancement Implementation Name and Description and click on
Next. The field ‘Enhancement Spot’ is automatically filled as the implementation is created
by directly clicking on the Enhancement Spot
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 4/16
Provide an existing transport request or create a new transport request and click on Finish
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 5/16
This will create an Enhancement Implementation. Now add a BAdI implementation by
clicking on ‘Add BAdI Implementation’ as shown below
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 6/16
Provide the BAdI definition name by clicking on the browse button and provide an
implementation name and click on Add
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 7/16
Provide a class name and click on Implementing Class. This will create a new class dialog
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 8/16
Provide the package name and description and click on Next. Provide an existing transport
request or create a new transport request and click on Finish
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 9/16
Save and Activate the class. Save and Activate the BAdI implementation once the class is
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 10/16
activated
Add the following logic in the method check document
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 11/16
Save and activate the class ZCL_FIELD_VALID.
As you can see, creating a BAdI implementation is much simpler now using Developer
Extensibility.
Now, when I try to save the Sales Order back in my Key User system(Development 100) with
the Field ‘Enhancement Field’ as empty, I will get the following message.
if salesdocument_extension-yy1_enhancementfield1_sdh IS INITIAL.
append value #( messagetype = 'E' messagetext = `This custom fie
messages.
endif.
1
2
3
4
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 12/16
The error message will be added to the log and can be seen as shown below
In addition to this, you can follow the blog SAP S/4HANA Key User Extensibility powered by
Embedded Steampunk: How to debug Key User Extensibilit... to debug and test your code in
the Development 100 system.
For more details on Developer Extensibility and how classic extension differs from
developer extensibility, you can follow the blog Embedded Steampunk – Some more details
for ABAP developers
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 13/16
3 Comments
Additionally, for queries on Developer Extensibility and language usage, you can follow the
blog ABAP language Versions FAQ
LABELS
Technology Updates
Former Member
2022 Sep 212:40 PM
1 Kudo
Great blog prasanthpadmanabhan.menon . Very well explained and can be used for
similar use cases.
-Saumi
Hongbo_Wang1
Product and Topic Expert
2022 Nov 033:27 AM
0 Kudos
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 14/16
Thanks for posting, but how it become different with 'custom logic' within key-user
extensibility?
PrasanthPadmanabhan
Product and Topic Expert
2022 Nov 034:02 AM
0 Kudos
Hi Hongbo,
The advantage here is that, you can debug the code directly in ADT and test the values
you wanted to populate into a custom field, or the BAdI you are implementing.
Debugging was not available in Key-User extensibility in 2SL systems. You can go thru
the blog https://blogs.sap.com/2022/07/20/sap-s-4hana-key-user-extensibility-
powered-by-embedded-steampunk-ho... for more details.
Best Regards,
Prasanth
You must be a registered user to add a comment. If you've already registered,
sign in. Otherwise, register and sign in.
Comment
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 15/16
Privacy Terms of Use
Copyright Legal Disclosure
Trademark Support
Cookie Preferences
Follow
9/29/25, 11:02 PM Add a validation to a Custom Field via Developer E... - SAP Community
https://community.sap.com/t5/enterprise-resource-planning-blog-posts-by-sap/add-a-validation-to-a-custom-field-via-developer-extensibility-in-sap-s/ba-p/13522589 16/16