Product Documentation

c-treeDB API for C++ - Developers Guide

Previous Topic

Next Topic

CTString::Insert

Syntax

void Insert(const CTString& substr, const NINT index)

Parameters

  • substr [in] The substring object to be inserted in the CTString object
  • index [in] The position in this string where substr will be inserted.

Description

Inserts substr into this string at position index. The first character position is 0. If index is zero Insert is similar to *this = substr + *this. If index is equal to Length then Insert is similar to *this = *this + substr. If index is less than zero or greater than Length, a CTException is thrown with error code set to CTDBRET_INDEXRANGE (4005). If substr is empty, no operation takes place.

Return

None.

See also

Delete()

TOCIndex