cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Data declaration without type

shrgrl
Participant
0 Likes
1,101

Hi all,
I'm trying to fix some issue. I have a tax invoice program for getting invoices. But amount labels are empty. I have to run a program and it involved the decleration:

DATA : lv_all.

And for run the program I must get into ELSE statement but I can't get into because lv_all is always empty.

IF lv_all IS INITIAL."for admin
...
ELSE. ... ENDIF.

When I get into ELSE statement, my issue is solving. But I don't understand why I'm using that declaration? Please explain and let me know.

Thanks in advance, best regards.

Accepted Solutions (1)

Accepted Solutions (1)

Dominik_Tylczynski
SAP Champion
SAP Champion

Hello shrgrl

It's hard to say precisely without seeing the entire code. The comment "for admin suggests that the value of the lv_all variable is meant to be changed under debugger and get into ELSE statement this way.

You can run the program in debug mode, modify lv_all and proceed with ELSE.

That is not a very best practice, but not that uncommon.

Best regards

Dominik Tylczynski

shrgrl
Participant

Hi 3a9e4ce873a94034b33dc62b0ce600ee,
Yes, I already going with that solution. But I thought it's not good way and am doing something wrong. But it's enough to hear that from you.

Thanks again,
Best regards.

Answers (0)