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: 

smartform - internal table

Former Member
0 Kudos

Hi all,

I developed a smartform, inside there's a internal tables with some fields.

In the form i maked the table, and all form's field is linked with table's field like below.

row2-->cell1 --> text1 with &Itab-matnr&.

cell2 --> text2 with &Itab-var2&.

cell3 --> text3 with &Itab-lifnr&.

cell4 --> text4 with &Itab-varrr&.

cell5 --> text5 with &Itab-montant&.

cell6 --> text6 with &Itab-tax&.

all run ok only if I delete cell5 --> text5 with &Itab-montant&.

I dont understand why cell5 --> text5 with &Itab-montant&. is wrong,

I checked and checked and it is like other.

some idea ????

tks a lot,

bye

1 ACCEPTED SOLUTION

MarcinPciak
Active Contributor
0 Kudos

Hi Roberto,

I think there are three possibilities:

1) cell or row addressing is wrong -> make sure you have right address typed in each cell of the table (1,1) (1,2) (1,3) ... - for first row, (2,1) (2,2) (2,3)....- for second and so on

2) you have some misspel in field names i.e. &Itab-montant& -> try to verify the names of the fields in ltab once again

3) ltab-montant is simply empty. To check this do the following:

- assign static vaule to ltab-montant -> add a 'CODE' node just before ''TEXT' node where you display data, and put there ltab-montant = some value. Then run the smartform and see if assigned value is displaying.

(Don't forget to add LTAB as importing and exporting parameter in CODE node)

- as above add 'CODE' node but this time just put there command 'BREAK-POINT'. It will create a static break point. Then run the smartform. When program stops at this point check what is in LTAB-MONTANT.

Sometimes the mistake is so simple, that hardly identyfiable. Maybe a fresh look next day will bring the solution.

Good luck

Marcin

8 REPLIES 8

MarcinPciak
Active Contributor
0 Kudos

Hi Roberto,

I think there are three possibilities:

1) cell or row addressing is wrong -> make sure you have right address typed in each cell of the table (1,1) (1,2) (1,3) ... - for first row, (2,1) (2,2) (2,3)....- for second and so on

2) you have some misspel in field names i.e. &Itab-montant& -> try to verify the names of the fields in ltab once again

3) ltab-montant is simply empty. To check this do the following:

- assign static vaule to ltab-montant -> add a 'CODE' node just before ''TEXT' node where you display data, and put there ltab-montant = some value. Then run the smartform and see if assigned value is displaying.

(Don't forget to add LTAB as importing and exporting parameter in CODE node)

- as above add 'CODE' node but this time just put there command 'BREAK-POINT'. It will create a static break point. Then run the smartform. When program stops at this point check what is in LTAB-MONTANT.

Sometimes the mistake is so simple, that hardly identyfiable. Maybe a fresh look next day will bring the solution.

Good luck

Marcin

0 Kudos

Hi Marcin,

tks a lot for your help, unfortunately I checked your point but not solved the problem.

But I checked sy-subrc after Call smartform and

sy-subrc = 1 it's mean that: formatting error.

itab-montant is type CURR in the table, ( but in other table, the type CURR is correctly printed ).

so, i dont now why sy-subrc = 1. The dimension of table is compatible,

so, help me!!

bye,

0 Kudos

Hi Roberto,

Have you assigned reference currency field to this .

If yes give some formatting options to this.

0 Kudos

Hi Bala,

how I can assing reference currency ?? I have to do it in smartform ? where ??

tks a lot

bye

0 Kudos

Hi Roberto,

I checked and sy-subrc is set to 1 at the very beginning of the smartform, so probably formatting is not an issue here.

What message excactly you get?

Can you run the smartform?

What does it print?

Does the system dumps out during the run?

If you provide more information similar to above it will be easier to help you.

Regards

Marcin

0 Kudos

hi,

the message is simply sy-subrc = 1 , and no other, the problem is:

if I put &itab-montant& in the smartform, the page is not print ( nothing is print ), but if i delete &itab-montant&, the page is correctly print and, of corse, the field itab-montant is empty.

no dump in the system.

I tried to change the type of itab-montant in char(5), is correctly, run correctly !!!

0 Kudos

Roberto,

Try to do what bala said. Assign reference to currency field. Do following:

go to Global Definitions -> tab Currency/Quant.Fields and type ltab-montant as your Field name and choose CURR as Data Type

BR

Marcin

0 Kudos

Thanks very very much,

I solved my problem !!!!!!!!

have you a nice day !!!!

bye