Page 1 of 1
How can I get image or voice clip size?
Posted: Thu Apr 24, 2014 1:45 am
by stevec
for saving to blob with size info field.
Is there an easier way than doing a directory list )ov_file_service get_dir) and locate fiel in list which has file size?
Re: How can I get image or voice clip size?
Posted: Mon Apr 28, 2014 9:59 am
by MarkDuignan
I can't think of any other was in RDMLX.
However - you might find some other solutions to retrieve an IFS file size in the general IBM i community forums?
If you can wrap the logic up in a program you should be able to call it from your RDMLX code.
There is a standard IBM API called stat() or fstat()
https://publib.boulder.ibm.com/infocent ... Ffstat.htm
that can return this information. You could call that from a very small CL program that binds to I think.
What OS/400 (iOS) version are you using?
Re: How can I get image or voice clip size?
Posted: Mon Apr 28, 2014 12:55 pm
by stevec
I created an rpg procedure (and wrapper for lansa since it does not support them) for stat and it works for files size.
Re: How can I get image or voice clip size?
Posted: Tue Apr 29, 2014 8:57 am
by MarkDuignan
is it possible to post the code - it would probably be useful to other forum users.
Re: How can I get image or voice clip size?
Posted: Tue Apr 29, 2014 9:20 am
by stevec
Re: How can I get image or voice clip size?
Posted: Wed May 14, 2014 12:09 pm
by MarkDuignan
Thanks for that.
Here's another useful IFS file program I encountered today -
http://www.itjungle.com/fhg/fhg051414-story02.html