TEXT_DELETE

TEXT_DELETE N,P,C

DELETES C CHARACTERS FROM POSITION P IN THE SYSTEM OBJECT NUMBER N

  • Type: Command
  • Parameters: 3
  • Group: System Objects

ACTION

The command TEXT_DELETE N,P,C deletes C characters from position P (that is from the P-th character) in the system object number N.

The system object is an EDIT, MEMO, COMBO, SPIN, MEMO_RICH, SYNEDIT.

SYNTAX: TEXT_DELETE N,P,C

  • N = system object number (integer or real). Must be greater than 0 and less than or equal to the allowed maximum number of system objects.
  • P = position of the first character to delete.
  • C = number of characters to be deleted.

USE

  • The command TEXT_DELETE is used to delete a part of the text in an EDIT, MEMO, COMBO, SPIN, MEMO_RICH, SYNEDIT.

ERROR

  • If number N is not a correct expression.
  • If number N exceeds the allowed maximum number of system objects.
  • If number N is less than 0.
  • If system object number N does not exist.
  • If number N is not the number of an EDIT, MEMO, COMBO, SPIN, MEMO_RICH, SYNEDIT.
  • If P is not a correct expression.
  • If P is less than or equal to 0.
  • If C is not a correct expression.
  • If C is less than or equal to 0.

EXAMPLE

rem create an EDIT

edit 1

rem display a text

text 1,"Hello world"

wait 1000

rem delete 3 characters from the 2sd

text_delete 1,2,3

SEE ALSO

EDIT

MEMO

COMBO

SPIN

MEMO_RICH

SYNEDIT

SELECT_READ$()

TEXT_INSERT