Syntax for labels

Is there any documentation, or can anyone give me an example showing the syntax for device labels?
I want to do something like this:

[ros_command(“:put [/system identity get name]”)] OR [Device_Name]
(ie, if it’s an ROS device, get it’s identity, otherwise use it’s name in The Dude).

Thanks

This works on the appearance of a device label…

[if("1","true","false")]

You should be able to do this

[if(ros_command(":put [/system identity get name]"), ros_command(":put [/system identity get name]), Device_Name)]

I don’t have time to get the syntax correct but it should work…

Lebowski

[if(string_size(oid(“iso.0.8802.1.1.2.1.3.4.0”))>1, ros_command(“:put [/system identity get name]”), “[Device.Name]”)]

Sorry, only just noticed your answers (didn’t see the notification).
That string works nicely. Thanks for your help.