Zoomed Image

AMSX Scripting Language - Command : generateuniquestring

Summary

Generate a deterministic unique string from a seed value

Description

Produces a string of the given length by selecting characters from the supplied character set using the seed value as a deterministic offset. Useful for generating short, reproducible identifiers such as licence keys or activation codes. Unlike GenerateRandomString, the same seed always produces the same output.

Parameters

ParameterDescription
cmddesired length of the output string (default 4)
Argument 0character set to draw from (leave blank for default alphanumeric set)
Argument 1numeric seed that drives character selection (default 1)
Argument 2true to reverse the resulting string, false to leave it as-is

Syntax


GenerateUniqueString "desired length of the output string (default 4)", "character set to draw from (leave blank for default alphanumeric set)", "numeric seed that drives character selection (default 1)", "true to reverse the resulting string, false to leave it as-is"

Return to the AMSX Command Reference