Questions

Post Reply
User avatar
rbytes
Posts: 1338
Joined: Sun May 31, 2015 12:11 am
My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet
Location: Calgary, Canada
Flag: Canada
Contact:

Questions

Post by rbytes »

Is there a file delete command?
I just searched the Files section and didn't see one.

Is there a command to give the size of an array? In the Save Font Names program I just posted, I used the #.fontlist command to create
an array containing all font names. But I didn't know how to read its size. I tried using, #.size(), but it just gave me the number of dimensions (1), not the number of elements. When I used #.writelines() to write the array to a file, I still could not figure out how many lines were written, so I could not add the line "x files written".
The only thing that gets me down is gravity...

User avatar
Mr. Kibernetik
Site Admin
Posts: 4786
Joined: Mon Nov 19, 2012 10:16 pm
My devices: iPhone, iPad, MacBook
Location: Russia
Flag: Russia

Re: Questions

Post by Mr. Kibernetik »

Function #.size returns number of elements in each dimension if to specify the dimension number as a second parameter. For one-dimensional array A it will be:

Code: Select all

#.output(#.size(a,1))

User avatar
rbytes
Posts: 1338
Joined: Sun May 31, 2015 12:11 am
My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet
Location: Calgary, Canada
Flag: Canada
Contact:

Re: Questions

Post by rbytes »

Thanks. I will implement this.

Any way to delete a file?
The only thing that gets me down is gravity...

User avatar
Mr. Kibernetik
Site Admin
Posts: 4786
Joined: Mon Nov 19, 2012 10:16 pm
My devices: iPhone, iPad, MacBook
Location: Russia
Flag: Russia

Re: Questions

Post by Mr. Kibernetik »

rbytes wrote:
Thu Sep 21, 2017 1:35 pm
Thanks. I will implement this.

Any way to delete a file?
No.
Good suggestion.

Post Reply