cancel
Showing results for 
Search instead for 
Did you mean: 

String in non-RFC table types

Former Member
0 Kudos

Hello all,

I have a structure that also have two members of ABAP type String (yes, that string, not char255 or so ). When I declare a table type inheriting from that type, everything is quite fine, so it seems table having dyn. Strings is okay as far as I do not want to do RFC with it.

Now, when I create a function module and want to use that table type, the compiler gives me that error message upon syntax check:

>>

when using "WITH HEADER LINE", the line type cannot be a table type

<<

Now, that is no ABAP that I have written but the auto-generator for the include. That line it complains, there is just no definition with a header line. So, is using the String type possible at all? I think this is an error having indirectly to do with it, since I know the difference on table with and without header line/work area and so...

Btw.: this is a 4.7 Release I am talking about.

Thanks and regards,

Timo

Accepted Solutions (1)

Accepted Solutions (1)

former_member225448
Participant
0 Kudos

Hi,

it is possible:

1. define your structure ZZ_DDIC_STRING with strings in DDIC

2. define a table type ZZ_DDIC_STRING_TAB using this structure ZZ_DDIC_STRING

3. define a RFC FM with Imp/Exp-parameters (not a Table-Param) using this table type ZZ_DDIC_STRING_TAB

4. call the FM:


DATA: lt_string_tab type ZZ_DDIC_STRING_TAB,
      ls_string_tab type line of lt_string_tab.

ls_string_tab-string1 = 'some text'.
ls_string_tab-string2 = 'some more text'.
append ls_string_tab to lt_string_tab.

CALL FUNCTION XYZ
    DESTINATION 'MY_DESTINATION'
    EXPORTING
      I_STRING_TAB = lt_string_tab[]
    IMPORTING
      E_STRING_TAB = lt_string_tab[]
    .

This will work with almost any deep structure too.

Regards,

Juergen

P.S.: pls. post Reward Points if this was usefull! Thanks!

Former Member
0 Kudos

Hey Juergen,

Thank you, that worked!

Can you please tell me wether the reward points reched you?

When I said "prob solved" I received a SDN exception that it failed. Then, the server was down again for 1h today and then I coukd not select anylonger to honor. On the otherway, that thread is not makred as "problem solved" and I also cannot see if you have received points in your profile.

Greets,

Timo

former_member225448
Participant
0 Kudos

Hi Timo,

so far you did not successfully set this message to "problem solved". Pls. try again

Regards,

Juergen

Former Member
0 Kudos

Hi,

Done

Now the radiobuttons were back again. In my login from this afternoon they were gone cos being saved in the session so, the rewarding process just worked half-way: not stored in DB but session flag saved :-).

Regards, Timo

Answers (0)