Case of Missing SAP Labels

One of my SAP GUI clients shows a somewhat abnormal screen as follows upon activating login screen :

The familiar label such as “Client”, “User”, etc is missing from screen, whereas other screen appear to be normally shown.

At first, I tried to activates trace function using highest level to see whether any of useful information regarding this matter is recorded into the trace log files. But I found none.

It’s time to examine the runtime behavour that’s causes the missing text.

After doing some debugging session, it is found that one of the routines responsible to show the label resides in CMyDraw::DrawLabel method inside sapfewdr.dll module. One of the parameters of this method is the string value, and in this case, it is of null value.

This null string value, in turn, is given by one of the property of CMyControl class of sapfewui.dll module via its SetText method. This method is actually called at control creation phase inside InitDynproControl function of sapfront.dll.

Now, SetText method actual string assignment is achieved via CSapBitmapDll::GetIconText of sapfewcls.dll. This method is supposed to successfully call the CSapBitmapDll::SAPab_icon_ptrX, but upon checking the pointer to this function before doing the calls, this pointer returns null value. This causes string assignment routine never gets called.

Functional pointer for Method SAPab_icon_ptrX is retrieved at the start up routines of SAP GUI via a call to CSapBitmapDll::GetProcAddresses.

At last, the above method calls Windows OS’s KERNEL32.GetProcAddress of the DLL file registered in its sapbtmp global variable. This variable is stored with C:\WINDOWS\system32\sapbtmp.dll.

Upon examining the exported functions inside the existing DLL, I can’t find SAPab_icon_ptrX in the list, so the case is closed after I find the right dll on the working machine 🙂

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: