So I've created an IBCollection Outlet in swift. Basically it is an array
I have an IBAction that creates a new button called
button and appends it to the array. So basically when I click a certain button, it adds other buttons. What I cannot figure out is how to get those buttons to then autolayout.
I really appreciate any help. Thank you so much
So, you want to autolayout programatic buttons.
First question is... are you getting these to lay out at all? Are they appearing in the view in any shape or form? If not, then your issue not an autolayout one, but rather, just an issue of adding them to the view (addsubview:)
If they are getting added, but autolayout is not toggling, you need to set constraints.
I suggest read this apple doc - it hits your nail right on the head!