Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


Runtime data binding

Binds the properties of any plain C# object to the properties of a UI control. You can use this type of data binding in the runtime UI. You can also use it in the Editor UI as long as it's not for serialized data.
Read time 1 minuteLast updated 6 days ago

Runtime data binding binds the properties of any plain C#
object
to the properties of a UI control. You can use this type of data binding in both the runtime and Editor UI. However, for serialized data in the Editor UI, use the SerializedObject data binding because it provides better support for Unity's serialization system, including undo/redo functionality and multi-selection operations.

Topic

Description

Get started with runtime bindingLearn the basics of runtime binding from an example.
Create a runtime data binding in C# scriptsCreate a runtime data binding.
Define a data sourceUnderstand how to define a data source for runtime binding, which can be any C# types.
Define binding modes and update triggersDefine binding modes and update triggers to configure how changes are replicated between the data source and the UI.
Convert data typesAdd type converters to convert data types between the data source and the UI.
Define logging levelsDefine logging levels to debug runtime bindings.
Create custom binding typesCreate custom binding types and attributes.
Runtime binding exampleLearn how to create a runtime binding from examples.

Additional resources