Saturday, 10 December 2016

ABAP TDD in NetWeaver 7.0 EHP2

I showed what the Test-Driven Development cycle might look like in the ABAP Workbench (SE80) in NetWeaver Release 7.01. Unfortunately, the TDD experience in that Release was marred by a hurdle right at the start of the process of implementing an ABAP class. That hurdle has been removed, and there are three other important improvements to ABAP Unit.

With NetWeaver 7.0 EHP2 (Release 7.02), the process has become a little bit more graceful. This weblog reviews what ABAP TDD looks like in practice in Release 7.02.  (Look for even more improvements in support for ABAP TDD in the Customer Engagement: Evaluation of the Pilot Version of ABAP in Eclipse.)

Friday, 9 December 2016

Customer Engagement: Evaluation of the Pilot Version of ABAP in Eclipse

Why ABAP in Eclipse?

The idea of offering an ABAP development environment in Eclipse may surprise some experienced ABAP developers, since the classical ABAP Workbench since years has proved itself as an integrated, comprehensive business development environment with a rich toolset for development, testing, troubleshooting and support running on a powerful server with a sophisticated, robust life cycle management. On the other hand Eclipse has established itself in the world as a state-of-the-art open development platform with the powerful UI capabilities, which are second to none and nowadays many developers are fascinated by its usability, productivity and flexibility.

Wednesday, 30 November 2016

MVC (model view controller) framework for ABAP part 1

What program type?

This is a question I have often reflected on. When I create an OO based dialogue application, what kind of program should I use? Since the program has to manage at least one dynpro, we could choose between three types of program for our application:
  • A module pool
  • A function group
  • A report

Friday, 25 November 2016

News in ABAP Debugger Breakpoints and Watchpoints ,Statement Debugging

SAP NetWeaver 7.0 EHP2 brings an expanded set of breakpoint and watchpoint capabilities as well as a new higher-resolution statement debugging capability (of course in the New ABAP Debugger!).

This blog shows how to use these new features:
  • The new types of breakpoint (on ABAP command, on Web Dynpro entities, on method of a class, on Simple Transformations…)
  • The new types of watchpoints (on internal table, on ABAP objects and object attributes…)
  • The new conditional breakpoints and watchpoints

Thursday, 24 November 2016

Displaying Internal Tables in the Debugger in NetWeaver 7.0 EHP2

The New ABAP Debugger, introduced with NetWeaver 2004s, came with a Table tool for displaying the contents of internal tables.

With NetWeaver 7.0 EHP2 and with Netweaver 7.30, the Table tool has been re-worked and expanded to make it easier to use and more flexible – a truly comfortable tool for examining internal tables, no matter how large or complex they might be.

Saturday, 12 November 2016

A second way to get the new ABAP editor in LSMW

In my previous blog ‘How to get the new ABAP editor in LSMW’ I described how a single enhancement enables the new ABAP editor in SAP’s LSMW. While that solution only takes one implicit enhancement spot, it has a few (minor) limitations. In this next blog I will describe another approach to enabling the new ABAP editor in LSMW. This new solution is slightly more invasive, but gives us much more flexibility.

Wednesday, 9 November 2016

How to get the new ABAP editor in LSMW

SAP LSM Workbench (LSMW) has for years been a much used tool for data migration into SAP. It is both loved and hated  While LSMW has had its last update in 2004 it remains a much used tool in this age of more modern toolsets such as SLT,  SAP DS and the like.

For many frequent and hard core users of LSMW a big nuisance is the old style ABAP editor. This old editor takes up alot of development time, especially in those ABAP-rich LSMW projects.

One night, bored and out of beer, I managed to develop a relatively simple enhancement that enables the new ABAP editor for LSMW.

Friday, 4 November 2016

SAP AS ABAP – Authentication using X.509 Client Certificates

This document shows how to configure SAP AS ABAP for authentication with x.509 client certificates. It shows the procedure used to create a simple Certification Authority (CA) using OpenSSL and how to generate client certificates from this CA.

Enabling SSL

Install the SAP Cryptographic Library. The following are minimal parameters to enable SSL
  • ssl\ssl_lib = S:\usr\sap\K20\SYS\exe\run\sapcrypto.dll
  • sec\libsapsecu = S:\usr\sap\K20\SYS\exe\run\sapcrypto.dll
  • sec\ssfapi_lib = S:\usr\sap\K20\SYS\exe\run\sapcrypto.dll
  • ssf\name = SAPSECULIB
  • icm\server_port_1 = PROT=HTTPS, PROT=1443, TIMEOUT=900
  • icm/HTTPS/verify_client = 1

Wednesday, 26 October 2016

SAP Screen Personas for Web Dynpro ABAP – Cross Session Scripting

Introduction

With SAP Screen Personas there is now the option to add client-side scripting to existing Webdynpro for ABAP applications.

With scripting it’s now possible to automate re-occurring or complex tasks. However there is a technical restriction: The script is always tied to the (technical) application. There is no possibility to define a script, which runs across different applications or even different browser windows. This heavily limits the applicability of scripting for automation.

Thursday, 20 October 2016

How to use C code via FBSL inside ABAP

The actual release candidate of Freestyle BASIC Script Language (FBSL) integrates a dynamic C JIT compiler, so is it possible to use ANSI C code inside FBSL. And with FBSLX, a COM library, you can use FBSL inside ABAP.

Here an example how to use ANSI C inside ABAP.

"-Begin-----------------------------------------------------------------
  Program zCMandelbrot.

Wednesday, 19 October 2016

MD5 calculation via ABAP and JavaScript

  1. Calculate MD5 for string “Jerry” via ABAP
  2. Calculate via JavaScript
1. Calculate MD5 for string “Jerry” via ABAP

Source code:

DATA: md5_160 TYPE hash160.
CALL FUNCTION 'CALCULATE_HASH_FOR_CHAR'
  EXPORTING

Saturday, 1 October 2016

Converting Excel file data with multiple sheets to an internal table

PREREQUISITES

It is expected that the readers have the basic knowledge of Function modules and considerable experience in ABAP workbench.
Also Check that EXCEL is registered in R/3 via transaction SOLE.

INTRODUCTION

Reading data from files is a very common requirement in project implementations. Excel spread sheets are simpler and better readable to text files. The standard ABAP function module ALSM_EXCEL_TO_INTERNAL_TABLE reads data from Excel file into internal table of type ALSMEX_TABLINE.

Thursday, 29 September 2016

Simple event handling in ABAP OOPS

Introduction:


This document is to show how to make a simple interactive report in OOPS by using event 'HOTSPOT_CLICK' present in standard sap class 'CL_GUI_ALV_GRID'.

I have taken a scenario of displaying the PO (Header and Item) data for a vendor by creating event driven interactive report. The program is created in ALV+OOPS. The interaction will be done on vendor number and PO document number.

The flow will be: - Vendor Details -> PO (Header) -> PO (Item)

Saturday, 24 September 2016

Language Translation Tool for SAP Technical Objects

Purpose:


The tool developed increases the efficiency of language translation objects as it helps in avoiding human errors. This tool also does the translation for Reports, Function groups, Includes in seconds. This tool not only saves time for translation but also helps in reviewing the translation done with an additional Excel tool.


Traditional method of LT


In most of the cases the Language translation for various Custom Texts is made available in Excel worksheet.
Below is sample screen shot of the same.

Monday, 12 September 2016

ABAP News for Release 7.50 - ABAP Channels Reloaded

ABAP Channels (ABAP Messaging Channels AMC and ABAP Push Channels APC) were introduced with ABAP 7.40, SP02, SP05. They enable an event based bidirectional communication between ABAP application servers and with the internet. For that, a dedicated Push Channel Protocol (PCP) can be used since 7.40, SP08. Before ABAP 7.50, the communication between ABAP servers and the internet was restricted to the Web Socket Protocol (WS) and the AS ABAP acting as a stateless APC server. The following features are new with ABAP 7.50:

Saturday, 3 September 2016

Output Catcher for ABAP

Output Catch is a small SAP server application to catch text on the presentation server from ABAP on the application server. You can send text direct to the editor of output catch, to a specific log file on the client, to a Windows debugger or to the Windows event protocol of the client.

It is very easy to use Output Catch:
  1. Register the Destination OUTPUTCATCH with the TAC SM59.
  2. Start the program OutptCatch.exe.
  3. Fill the connection parameters.

Thursday, 14 July 2016

Dynamic FM call with extra parameter

Use Case 


Consider the scenario in your development, you are reusing a standard FM in your program which is having 2 mandatory import parameters . And you shipped the solution to the customer. Now same FM in the customer system is having one more additional mandatory importing parameter. Now when your program runs and that calls the FM the dump appears in customer system. How to resolve this issue. This can be done by calling the FM dynamically with extra parameter that is not in your system but it is there in customer system. The below post tries to show the same.

The  FM ‘FPM_DEMO_FLIGHT_GET_CARRIER’ having below details as one import and one export parameter.