Hi,
I’ve got a problem with insert function.
Hereunder, you can read my code:
LIMCommentLine.RESET;
LIMCommentLine.SETFILTER(“Table Name”,FORMAT(LIMCommentLine.“Table Name”::Application));
LIMCommentLine.SETFILTER(“No.”,Application.“No.”);
IF LIMCommentLine.FIND(’-’) THEN
REPEAT
LIMCommentLine.VALIDATE(“Table Name”,LIMCommentLine.“Table Name”::Policy);
LIMCommentLine.VALIDATE(“No.”,NewPolicy.“No.”);
LIMCommentLine.INSERT;
UNTIL LIMCommentLine.NEXT = 0;
I have a bunch of lines like written below:
Type | App. No. | Line No. | Content |
Application | AP00001 | 10000 | monday |
Application | AP00002 | 20000 | thursday |
Application | AP00003 | 30000 | sunday |
And my code should insert new lines with new type and new app no. but keep the line no. and the content:
Type | App. No. | Line No. | Content |
Policy | PO00001 | 10000 | monday |
Policy | PO00002 | 20000 | thursday |
Policy | PO00003 | 30000 | sunday |
…
The first line is modified correctly but it stops at this point. When I manually changed the line, it inserts a new empty row … Then I suppose that the repeat loop breaks because of it.
How should I turn my code to avoid this additional blank line?
Thanks