0

I am using UICollectionView with header and UISerach bar also. Now i am getting issue my header is coming top of search bar. How to change the y position enter image description here

i want UISearch bar then my collectionview header. But header not moving down .

Cœur
  • 37,241
  • 25
  • 195
  • 267

1 Answers1

0

Either u accidentally dragged the header into the search bar or u can change the y value of the header by going into the utilities and clicking the ruler then u will see a section called view and there will be a y and you can change the y value there. if created programmatically then u had to use this line of code.

searchBar.frame = CGRectMake(x,y,width,height);

that sets the searchbars position and width and height so just change the y value to something higher than the header since the y value goes top to bottom. And u replace searchBar with whatever you named your search bar

Max
  • 318
  • 1
  • 3
  • 11
  • can you show me screen shot i am not getting .uisearch bar i created via programmatically –  Jul 14 '15 at 05:03