Strdel

From SA-MP Wiki

Jump to: navigation, search

strdel

Image:Farm-Fresh text lowercase.png Note: This function name starts with a lowercase letter.


Description:

Delete part of a string.


Parameters:
(string[], start, end)
string[]The string to delete part of.
startThe position of the first character to delete.
endThe position of the last character to delete.


Return Values:

This function does not return any specific values.


Example Usage:

new string[42] = "We will delete everything apart from this";
strdel(string, 0, 37); // string is now "this"

Related Functions

The following functions may be useful, as they are related to this function in one way or another.

  • strcmp: Compare two strings to check if they are the same.
  • strfind: Search for a string in another string.
  • strtok: Get the next 'token' (word/parameter) in a string.
  • strins: Insert text into a string.
  • strlen: Get the length of a string.
  • strmid: Extract part of a string into another string.
  • strpack: Pack a string into a destination string.
  • strval: Convert a string into an integer.
  • strcat: Concatenate two strings into a destination reference.
Personal tools
In other languages