0

If I have the views added in Interface Builder and not as addSubView in program Can Use bringSubViewToFront , sendViewToBack? do I need to define loadView in order to use them Because I am trying to use it in ViewDidLoad but it returns undefined method.

I have some views in IB I want to send it back? bring other View in front using some boolean variables ? IS that possible in IB or I have to use bringSubViewToFront , sendViewToBack methods? How to use these methods in my case? many thanks

Dina
  • 467
  • 4
  • 18
  • For your uiViews in IB did you create IBOutlets in your code and connected them correctly in IB? – Cyprian May 03 '11 at 19:18
  • yes, I have the bringViewToFront works now. – Dina May 03 '11 at 20:33
  • However I have a problem with UITextField when I am implementing self.myTextField.hidden = FALSE; [self.view bringSubviewToFront:destinationTextField]; is not showing ? is there something special to show or hide TextField other than these methods ? – Dina May 03 '11 at 20:38

1 Answers1

0

Note that the methods are:

-bringSubviewToFront
-sendSubviewToBack
-viewDidLoad
-addSubview

You can set the hierarchy by the ordering of the views in Interface Builder.

InsertWittyName
  • 3,930
  • 1
  • 22
  • 27
  • i didn't get u. can u explain, what do u mean by set the hierarchy ? – Dina May 03 '11 at 20:42
  • self.myTextField.hidden = FALSE; [self.view bringSubviewToFront:myTextField]; is not bringing it to the front , what could be the problem. plz note that the hidden is not checked in IB – Dina May 03 '11 at 21:43