0

Whenever I try to compile my Xcode project I get error cannot find protocol declaration for UIScrollViewDelegate

I have cleaned my project multiple times but nothing seems to solve the issue.

Also I have an error could not build module UIKit I am unable to fix the issue for long as my project does not build.

Avinash Sharma
  • 665
  • 1
  • 7
  • 23

3 Answers3

0

To be able to build UIKit again, Clean derived data.

Once it has been build the delegate will be found also.

Community
  • 1
  • 1
shallowThought
  • 19,212
  • 9
  • 65
  • 112
  • Please post the target you build against (iPhone 6 Simulator, 10.1 for instance) and your Deployment Target. Try if other combinations work. – shallowThought Dec 29 '16 at 23:09
0

Make sure that you haven't made any changes in Foundation framework accidentally!!! I mean in any class of UIKit!!

If above is not the case then full clean and deleting derived data should work!

You couldn't building UIKIt so you are unable to find UIScrollViewDelegate I think, but it's depends on another cases also!

Ketan Parmar
  • 27,092
  • 9
  • 50
  • 75
0

Try following may be it will help:

  1. Removing and adding UIKit.framework in Build Phases -> Link Binary With Libraries.

  2. Check that you have not typed anything or modified anything in UIKit.framework header files.

    May be in UIKit.framework-->Headers-->UIScrollView.h in your case.

Community
  • 1
  • 1
Ronak Chaniyara
  • 5,335
  • 3
  • 24
  • 51