[Unity] Adding controls to a canvas programmatically
Posted: 13 May 2014, 16:46
I'm trying to add some controls to a Canvas element programmatically. In other XAML based frameworks, I'd simply create the control and add it to the Canvas's Children, like so:
However, this does not appear to work in Noesis GUI. The Canvas control doesn't expose a Children property. Is there any other way to add items programmatically?
Code: Select all
var button = new Button();
myCanvas.Children.Add(button);