SAP read the file size during run time

In SAP when you are uploading the file from desktop you wish to restrict the file size.

To do this we can call the Class CL_GUI_FRONTEND_SERVICES Method FILE_GET_SIZE. There are many blog that consultant are not getting the output from the class.

Try adding the CL_GUI_CFW=>FLUSH( ) just after the call of the above method hope it will solve your problem.