Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

call winhelp from ABAP programs

Former Member
0 Kudos

Hi,

I'm trying to display a windows help file in my ABAP application.

The idea: by pressing the info-button it should display the file "Info.chm".

I can display the file, if it is placed locally on the client machine, but I

want to store it in the system somehow, so that it is available to all of the

users.

How can I place it in some repository, and later call the HtmlHelp Application?

I saw an old example calling

CALL FUNCTION 'WIN_HELP' FROM 'SAP_GUI'

...

but it doesn't work anymore.

Best regards,

Stanimir

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Stanimir,

You could try putting the help into the SAP Web repository (transaction SMW0). It has a section for storing binary (MIME) objects. This will store the help as a binary object within the SAP database.

What you do is upload the help file into the repository, and then assign an application (MIME editor) to the object based on its extension. In your case you could assign the HTML help to .chm extensions (first you may have to maintain .chm as a MIME type).

Then to execute the application by calling function SHOW_WEB_OBJECT and passing the attributes of the object using the KEY parameter.

Hope that helps.

Cheers,

Brad

6 REPLIES 6

Former Member
0 Kudos

Hi Stanimir,

You could try putting the help into the SAP Web repository (transaction SMW0). It has a section for storing binary (MIME) objects. This will store the help as a binary object within the SAP database.

What you do is upload the help file into the repository, and then assign an application (MIME editor) to the object based on its extension. In your case you could assign the HTML help to .chm extensions (first you may have to maintain .chm as a MIME type).

Then to execute the application by calling function SHOW_WEB_OBJECT and passing the attributes of the object using the KEY parameter.

Hope that helps.

Cheers,

Brad

0 Kudos

Hi Brad,

thank you very much!

It works exactly as I wanted!

Cheers,

Stanimir

0 Kudos

No problem, glad to help.

Good to see the repository used in this way (I think it is often overlooked).

Cheers,

Brad

0 Kudos

Brad,

I created the object in the SAP Web repository, transaction SMW0. These are the attributes of the object.

Z_SAP_HELP fileextension .chm

Z_SAP_HELP filename C:\Temp\SAP_help.chm

Z_SAP_HELP filesize 28686

Z_SAP_HELP mimetype chm

Z_SAP_HELP version 00001

I created a new Mine type: chm with extension *.chm

I associated %SystemRoot%\hh.exe as the editor for Mime type chm.

This worked fine for me, but my colleague was unable to successfully run SHOW_WEB_OBJECT until he also set up the editor associated with Mime type chm. Is there a way to systemically set up the association between a mime type and the editor so that each person does not have to go through this process?

Thanks

Bruce

0 Kudos

Hi Bruce,

I just checked it out. When you record your MIME editor for a MIME type it exports it to the database table WWWDATA with the key:

RELID: ST

OBJID: mimeappl<username>

There doesn't seem any way to automate this using standard functionality, but you could write your own program to export the correct contents to database for each of your users. I think you could achieve this by doing an external perform on the subroutine SET_MIMETYPES in program SAPLSHTM (function group SHTM).

Hope that helps.

Brad

0 Kudos

Brad,

Thanks for the quick reply. It wasn't the answer that I was hoping for, but you did provide me with a solution. It does seem silly that this association can't be set up systemically. But who were we to question the decisions that SAP developers made in the dark of night as they developed the product.

Enjoy your weekend.

Bruce