file size
Phil Davis
revdev at pdslabs.net
Tue Sep 23 00:18:53 EDT 2014
If you want to do it entirely in LC and not use a shell command, you
could do this:
on mouseUp
answer file "Pick a file:"
if it is empty then exit to top
set the itemDelimiter to slash
put the defaultFolder into tOriginalDefault
set the defaultFolder to item 1 to -2 of it
put the detailed files into tList
set the defaultFolder to tOriginalDefault
filter tList with urlEncode(last item of it) & ",*"
set the itemDelimiter to comma
answer "Length of file" && quote & first item of tList & quote &&
"is" && item 2 of tList && "bytes."
end mouseUp
Phil Davis
On 9/22/14 2:29 PM, larry at significantplanet.org wrote:
> Hello,
>
> I know I can use:
> put the files into field "Current Files"
>
> to get the size of a file (in bytes), but is there any way to use "answer file" or some other way to get the size of just one specific file?
>
>
>
> Thanks,
>
> Larry
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
--
Phil Davis
More information about the use-livecode
mailing list