Announcement:
wanna exchange links? contact me at sapchatroom@gmail.com.
Posted by
Admin at
Reply from LCC352 on Feb 16 at 4:35 PM Ah. So the write statement works but the ALV does not. First, an ALV is generally not 'variable' as you would like it to be. That is why I stated in my first email that you want ONE field which would hold EITHER the phantom value OR the standard value. You have TWO fields, and you're looking to have one or the other show up in the grid. That is what is going to give you a problem. The field in the grid needs to be constant format and source. The value in that constant can definitely be different. Try populating a single field with the value you want based on the IF-THEN-ELSE. Then, put THAT field in the grid. Lou >
| | | ---------------Original Message--------------- From: VINOD RAAGHAV Sent: Sunday, February 16, 2014 5:40 AM Subject: Using Dynamic Field Catalog it is the 9 th col i.e as said above I tried to loop the internal table it_cat into wa_fcat and use if...else statement like this... loop at it_fcat into wa_fcat. if it_final-sobsl = '50 '(sobsl is the field which denotes material is phantom in material master) WA_FCAT-COL_POS = COL_POS + 8 . WA_FCAT-ROW_POS = ROW_POS . WA_FCAT-FIELDNAME = 'PHANTOM'. WA_FCAT-TABNAME = 'IT_FINAL'. WA_FCAT-SELTEXT_L = 'S.LOC'. WA_FCAT-OUTPUTLEN = 10. WA_FCAT-EMPHASIZE = 'C21'. APPEND WA_FCAT TO IT_FCAT. CLEAR WA_FCAT. ELSE. WA_FCAT-COL_POS = COL_POS + 8 . WA_FCAT-ROW_POS = ROW_POS . WA_FCAT-FIELDNAME = 'LGPRO'. WA_FCAT-TABNAME = 'IT_FINAL'. WA_FCAT-SELTEXT_L = 'S.LOC'. WA_FCAT-OUTPUTLEN = 10. WA_FCAT-EMPHASIZE = 'C21'. APPEND WA_FCAT TO IT_FCAT. CLEAR WA_FCAT. ENDIF. ENDLOOP. I don't know how to proceed here...when I use the above if...else it skips the whole column and prints the next column...probably something wrong with my if condition ? while using 'write' statement I am fine I am getting it right. | | Reply to this email to post your response. __.____._ | In the Spotlight Become a blogger at Toolbox.com and share your expertise with the community. Start today. _.____.__ |