the normal scalar variable syntax ${var}, how to use variables in list and dictionary contexts like @{var} and &{var}, respectively, and how to use environment variables like %{var}
By default if you declare a scalar variable it’s a string, e.g.:
VAR ${stringscalar}= 3
if you need a numeric value you can declare them like this:
VAR ${numericscalar}= ${3}
For other variable types you may need to use Evaluate to get python to return the type you need.
If your still let us know what type of variable you need to create and we can try to help,
button is only allowed to be of the enum type MouseButton. I’d like to do that with a user keyword and without going through the hassle of coding it in python.
Ah I see what you mean, unfortunately I don’t know the answer, hopefully someone else can help
However I’m also not sure if you need to do that? for example when I look at the documentation for Click, I see in the examples that you just pass the string left or right so perhaps try something like this:
I believe that @pekkaklarck mentioned in this video: RoboCon 2024 - What’s new in Robot Framework 7.0 and why you should update!, that literals can be used to enforce certain values in keywords implemented in Python, but that it is not yet possible for keyword implemented in RobotFramework.
Maybe it will come in a future release? If no enhancement request is already open on the topic we should definitly open one!