//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "SysUtilsStrPos.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
	: TForm(Owner)
{
}
//---------------------------------------------------------------------------
// BeginExample: SysUtilsStrPos
// Routine: SysUtils.StrPos

// BeginCode
/*
The following example uses two edit controls and a button on
a form. When the button is clicked, the text in the first
edit control is searched for the text in the second edit control.
*/
void __fastcall TForm1::Button1Click(TObject *Sender)
{
  if (StrPos(Edit1->Text.c_str(), Edit2->Text.c_str()))
    ShowMessage("Substring found.");
  else
    ShowMessage("Substring not found.");
}
// EndCode
// EndExample: SysUtilsStrPos
//---------------------------------------------------------------------------
