prop_filesize.htm
Navigation: Language Reference > App C - PROP: Runtime Properties > Runtime VIEW and FILE Properties >====== PROP:FileSize ====== | |
file{PROP:FileSize}
file | The label of the file, or a property that references a file label. |
PROP:FileSize returns the number of bytes in the file. BYTES() returns the file size until the first record access, then it returns the size of the last read record. PROP:FileSize can be used to return the full file size after the first GET/NEXT/ADD statement.
Example:
ProcessClass.Reset PROCEDURE
CODE
SELF.RecordsProcessed = 0
IF ~SELF.StepMgr &= NULL
SELF.SetProgressLimits
ELSIF ~SELF.RecordsToProcess
SELF.Primary.Me.UseFile
SELF.RecordsToProcess = RECORDS(SELF.Primary.Me.File)
IF ~SELF.RecordsToProcess ! Records not supported
SELF.FileSize = SELF.Primary.Me.File{PROP:FileSize}
END
END
SELF.ChildRead = 0
PARENT.Reset
prop_filesize.htm.txt · Last modified: 2021/04/15 15:57 by 127.0.0.1