Skip to Content

[Beginner] Transferring parameters between Pages

Hi,

It is my first BSP Application.

I have troubles transferring parameters from one page to the other. It seems that nothing is transferred at all !

My BSP application is : <b>Stateful</b>

It has 2 pages :

start.htm

report.htm

In the OnInputProcessing handler, I use these statements to pass on data from start.htm to report.htm :

        navigation->set_parameter( name = 'LAUNCH_DATE' value = w_launch_date ).
        navigation->set_parameter( name = 'LAUNCH_TIME' value = w_launch_time ).

        navigation->next_page( 'TOREPORT' ).

Besides, my Page attributes in report.htm (which has the 'TOREPORT' navigation request) are defined as follows :

<b> Name Auto Typing Assoc. Type Description</b>

LAUNCH_DATE X TYPE D Date of launch

LAUNCH_TIME X TYPE T Time of launch

Please, could you see what is missing ??

Thanks in advance.

Cheers,

Guillaume

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Oct 19, 2005 at 10:49 AM

    HI Guillaume,

    To pass the parameters you don't have to make the application stateful.

    Please try doing the following changes.In onInputProcessing

    navigation->goto_page( 'report.htm' ).

    instead of navigation->next_page( 'TOREPORT' ).

    Also ensure that in the second page(report.htm),the page attributes LAUNCH_DATE and LAUNCH_TIME should be checked to AUTO .

    Hope this helps,

    Regards,

    Siddhartha

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 19, 2005 at 10:54 AM

    Hi Guillaume,

    Try giving <b>toreport</b> instead of TOREPORT as navigation request. Let us know if it works.

    Regards,

    Ravikiran.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 19, 2005 at 12:12 PM

    Thanks for you recommendations !

    Actually, it seems that what was preventing report.htm to get the values of the attributes was the Type. Indeed, I declared them as Type D and Type T whereas the set_parameter automatically converts them into STRING.

    Therefore, I declared them as STRING and I add this bit of code and everything goes well now !

    DATA : w_launch_date     TYPE d,
           w_launch_time     TYPE t.
    
    *_ Convert Date attribute
    CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'
      EXPORTING
        date_external            = launch_date
      IMPORTING
        date_internal            = w_launch_date
      EXCEPTIONS
        date_external_is_invalid = 1
        OTHERS                   = 2.
    IF sy-subrc <> 0.
      w_launch_date = sy-datum.
    ENDIF.
    
    *_ Convert Time attribute
    CALL FUNCTION 'CONVERT_TIME_INPUT'
      EXPORTING
        input                     = launch_time
      IMPORTING
        output                    = w_launch_time
      EXCEPTIONS
        plausibility_check_failed = 1
        wrong_format_in_input     = 2
        OTHERS                    = 3.
    IF sy-subrc <> 0.
      w_launch_time = sy-uzeit - 10.
    ENDIF.

    Thanks again.

    Cheers,

    Guillaume

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.