UserLand Software Home  |  Manila  |  Radio  |  Support  |  News

DocServer

Prev | Next | String Verbs > string.delete

string.delete

Syntax string.delete (string, index, count)

Params string is the string on which the operation is to be performed.

index is the starting position in the string where deletion should begin.

count is the number of characters to be deleted.

Action Deletes count characters in string, beginning at position index.

Returns Resulting string.

Examples string.delete ("Programming is not too much fun!", 16, 4)

   » Programming is too much fun!

string.delete ("Too many characters spoil the pot roast.", 20, infinity)

   » Too many characters

In the example above, any value larger than 21 would have the same effect.

Notes Index is 1-based (in other words, the first character in a string is referenced as character 1, not, as in many programming languages, character 0).

You can use sizeOf to determine the length of string.

See Also sizeOf

Prev | Next | String Verbs > string.delete

Anonymization by Anonymouse.org ~ Adverts
Anonymouse better ad-free, faster and with encryption?
X