Show / Hide Table of Contents

Storage.Delete Method (StorageContext, string)

Deletes a value from the peristent store based on the given key.

Namespace: Neo.SmartContract.Framework.Services.Neo

Assembly: Neo.SmartContract.Framework

Syntax

public extern void Delete(Neo.SmartContract.Framework.Services.Neo.StorageContext context, byte[] key)

Parameters:

Context: Storage context as a StorageContext .

Key: Key as a string.

Return value: void.

Example

public class Contract1: FunctionCode
{
     public static void Main()
     {
         Storage.Delete(Storage.CurrentContext, "Key");
     }
}

Back