Performs a DELETE on an SRP Fast Array.
Syntax
SRP_FastArray_Delete(Handle, Field, Value, SubValue)
Parameters
Parameter | Description |
---|---|
Handle | Handle to an existing SRP Fast Array (REQUIRED) |
Field | Field position (REQUIRED) |
Value | Value position (REQUIRED) |
SubValue | SubValue position (REQUIRED) |
Remarks
The SRP_FastArray_Delete method mimics the BASIC+ Delete function and works exactly the same way. Pass the Field, Value, and Subvalue positions of the element you want to delete. To delete a whole field, set Value and SubValue to 0. To delete a whole value, set SubValue to 0.
IMPORTANT: You should always release the handle to an SRP Fast Array when you no longer need it by calling SRP_FastArray_Release.
Examples
// Create an empty fast array Handle = SRP_FastArray_Create() // Insert several values SRP_FastArray_Insert(Handle, 1, 2, 0, "ABC":@SVM:"DEF") SRP_FastArray_Insert(Handle, 2, 0, 0, "EFG") SRP_FastArray_Insert(Handle, 3, 1, 7, "HIJ") // Delete ABC SRP_FastArray_Delete(Handle, 1, 2, 1) // Get the final array Variable = SRP_FastArray_GetVariable(Handle)
The final variable looks like this:
<1> <1, 1> <1, 2> DEF <2> EFG <3> <3, 1> <3, 1, 1> <3, 1, 2> <3, 1, 3> <3, 1, 4> <3, 1, 5> <3, 1, 6> <3, 1, 7> HIJ