- Found in:
- SKSE
Description
Wiki Description
Returns the character at the given index in the given string. (This function requires SKSE)
Documentation Comment
returns a single character string with the character at index
Caveats
CK Wiki - Notes
- Papyrus strings are case-insensitive. See Literals Reference > String > Case Insensitivity) for more.
Parameters
strings
CK Wiki Description
The string to search in.
intindex
CK Wiki Description
The index of the character in the string.
Examples
string posInString = StringUtil.getNthChar("Hello, World!", 4)
debug.notification("Character at position 4 in the given string is " + posInString + ".")
debug.trace("Character at position 4 in the given string is <" + posInString + ">.")
; Character at position 4 in the given string is <O>.import StringUtil
;;;
string posInString = getNthChar("01234567", 5)
int x = posInString as int
debug.notification(2 * x)
; 10Auto-Generated Example
string myString__s
int myInt__index
string returnedValue = StringUtil.GetNthChar(myString__s, myInt__index)