StructClear

Removes all data from a structure.

StructClear( structure )

Returns: Boolean

Argument Description
structure
struct, required

Structure to clear

Examples

Member Function

animals = {
	cow: "moo",
	pig: "oink"
};
// Show current animals
Dump(
	label: "Current animals",
	var: animals
);
// Clear struct
animals.clear();
// Show animals, now empty
Dump(
	label: "Animals after calling struct.clear()",
	var: animals
);

Non-Member Function

animals = {
	cow: "moo",
	pig: "oink"
};
// Show current animals
Dump(
	label: "Current animals",
	var: animals
);
// Clear struct
structClear(animals);
// Show animals, now empty
Dump(
	label: "Animals after calling StructClear()",
	var: animals
);

See also