Skip to content
Narta Xaymar Dirks edited this page Oct 28, 2026 · 6 revisions

Blitz3DBlitzPlusBlitzBasic

Instr

Instr:Int32 string:String, find:String, from:Int32=1
Parameter Mode Type Default Description
string In String required The text to search in.
find In String required The text to look for.
from In Int32 1 Position to start searching at. Defaults to 1.

Returns: The position of the first match, or 0.

Description

Finds the first position of a piece of text inside another string. Positions start at 1, and 0 means it was not found. The search tells upper and lower case apart.

Examples

Print Instr("hello world", "o")
Print Instr("hello world", "o", 6)
Print Instr("hello", "z")
5
8
0

Related Commands

Chr, Hex, Left, Len

Home · Command Index



Differences
Language Features
BlitzBasic
Blitz3D
BlitzPlus

Clone this wiki locally