Search code examples
iosobjective-cnslayoutconstraint

NSLayoutConstraint format


The First image is use else if, after I change if, when compile is not have any issue until I click other page then have a error, the error is

NSInvalidArgumentExeception, reas: 'Unable to prase constraint format: @"V:[allCssLabel]-0-[individualLabel]"

I try to change @"V:|-[allCssLabel]-0-[individualLabel]-|", still have a error, I want to know how to fix the problem enter image description here enter image description here


Solution

  • Views in "format" should correspond views in variable bindings dictionary. You have incorrect name in variable bindings