I'm writing a file in iSeries IFS.
My variable File_Data is a 32000A, so when I use
CallP Write(FileD :
%Addr(File_Data) :
%Size(File_Data) )
I find some unuseful spaces when the Variable is not filled for 32K chars. I try with a %Trim but I get an Error.
To bypass the problem I do this:
For Counter = 1 To %Len(%Trim(File_Data))
Eval SingleChar = %SubSt(File_Data : Counter : 1)
CallP Write(FileD :
%Addr(SingleChar) :
%Size(SingleChar) )
EndFor
Is there a better way to do this? Becasue is very slow.