SAP ABAP: Send Email with attached Internal Table XLS file

Below you will find a quick guide of how to set up a FM in your system that will take as input an internal table, convert that table in to XLS format and send out an email with the attachment. Add the appropriate import parameters. Add appropriate table parameters. if recepients[] is
Continue Reading →

SAP ABAP: referencing caller program’s variables within a CALL’ed FM

When executing a CALL command there is a way to access the variables of a caller program – see sample code below. REPORT zcustom_caller. DATA: gv_a TYPE i, gv_b TYPE i, gv_c TYPE i. gv_a = 1. gv_b = 2. gv_c = 3. CALL FUNCTION 'z_custom_called' EXPORTING i_a = gv_a IMPO
Continue Reading →

SAP ABAP: reading payload via IF_HTTP_EXTENSION class

The process of creating a RESTful handler in SAP is a relatively simple process.  Simply create a new class extending an interface IF_HTTP_EXTENSION and implement the HANDLE_REQUEST method. As part of the implementation you will get access to the SERVER parameter: server TYPE REF TO i
Continue Reading →

SAP Gateway: parse ATOM data using jQuery

There’s a widely held belief that because the SAP NetWeaver Gateway system does not yet output OData messages in JSON format  [Version 2 SP3], that therefore it is not possible to consume Gateway services directly from JavaScript. This How-To Guide demonstrates that it is in fac
Continue Reading →

Adobe Flex 4.5 vs 4.6 input fields overlay/overflow problem in Mobile Development

This particular problem has puzzled me for quite some time now.  Imagine the following scenario: <?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark"
Continue Reading →

SAP tp: return codes

For each step that takes place within the tp command there could be 8 different possible return codes [0, 4, 6, 8, 12, 13, 14, 16]. The meaning for each of those codes is as follows: Transport imported successfully: 0: Transport successful 4: Warning occurred Transport did not import
Continue Reading →

SAP: debugging in pop-up windows

Debugging in SAP is something that I do almost on a daily basis, most of the time I get by just by typing the /h command in the transaction window and executing the program but this is not always possible. The scenario that I speak of occurs when you are debugging a pop-up window.When
Continue Reading →

ABAP cancelling an SD Billing Document

If you have access to a billing document number try executing the following function: DATA: l_rtrn TYPE bapireturn1 OCCURS 0. DATA: l_succ TYPE bapivbrksuccess OCCURS 0. CALL FUNCTION 'BAPI_BILLINGDOC_CANCEL1' EXPORTING billingdocument = * testrun = * no_commit = billingdate
Continue Reading →

FM: SAPGUI_PROGRESS_INDICATOR

A usefull little function that will allow you to display a status update on the bottom left corner of the screen when running your reports. call function 'SAPGUI_PROGRESS_INDICATOR' EXPORTING percentage = 0 text = STATUS_TEXT. Note: anything lower then 0 will be rounded up t
Continue Reading →