Skip to Content
avatar image
Former Member

Calling a R/3 transaction in a BSP

Hello,

we have developed a BSP-MVC application in CRM 4.0 and we're trying to call a R/3 transaction, to do that we are calling a RFC function from an event of our BSP source. The RFC function only call the transaction but it doesn't work (The page cannot be displayed), however if we execute the program in debug mode and we define breakpoints in it, the call stops in each breakpoint and then a R/3 mode with the transaction appears over our CRM program. does anybody know what is the problem? what is the different betweeen debug execution and normal execution?

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • Oct 22, 2003 at 05:59 PM

    Hallo Mario,

    The answer is simple, just slightly complex to describe. Let me use my words, and some vague handwaving to explain.

    When you log onto a webAS system the dynpro engine is started that contains all the logic to handle interaction with the SAPGUI. For example, things such as rendering controls, doing file upload, running ActiveX controls, etc.

    When you run a HTTP request into webAS (which is the case for BSP), a very special "dark" dynpro is started. The dynpro is required to get all ABAP, etc. up and running. But now there is no SAPGUI available, so things such as control rendering, doing file upload via gui upload, etc will not work. Also little things such as popup windows, etc does not work. Or things such as a RFC suddenly wanting to display a dialog to ask for username and password.

    So why does your code work only in debugger? Because once the debugger is triggered, like in the very first few steps, it is realized that a normal dynpro engine is required, and not the "dark" one. So the full blown dynpro engine is started.

    If this transaction requires a GUI, it will NOT work in BSP. This can not be changed.

    You can only consider to find the code that causes the error, and bracket it with IF statements in this transaction so that no GUI interaction is required in context of a HTTP call.

    brian

    Add comment
    10|10000 characters needed characters exceeded