2
아래 코드를 사용하여 텍스트 파일에서 빈 줄을 삭제하지만 작동하지 않습니다.Inno 설치 : 테스트 파일에서 빈 줄을 삭제하십시오.
function UpdatePatchLogFileEntries : Boolean;
var
a_strTextfile : TArrayOfString;
iLineCounter : Integer;
ConfFile : String;
begin
ConfFile := ExpandConstant('{sd}\patch.log');
LoadStringsFromFile(ConfFile, a_strTextfile);
for iLineCounter := 0 to GetArrayLength(a_strTextfile)-1 do
begin
if (Pos('', a_strTextfile[iLineCounter]) > 0) then
Delete(a_strTextfile[iLineCounter],1,1);
end;
SaveStringsToFile(ConfFile, a_strTextfile, False);
end;
도와주세요. 미리 감사드립니다.
TLama @ 답장을 보내 주시면 감사하겠습니다. – user1752602
당신을 진심으로 환영합니다! – TLama