SideDrawer:() DidSelectItemAtIndex() NOT BEING CALLED WHEN ITEM CLICKED

8 posts, 1 answers
  1. Cameron
    Cameron avatar
    5 posts
    Member since:
    Nov 2015

    Posted 20 Nov 2015 Link to this post

    Hi -

    Having difficulties setting up a SideDrawer as it refuses to listen to the TKSideDrawerDelegate method, (DidSelectItemAtIndex:)

    My application runs with an initial login page and push segue to new user sign-up view. Upon login, a TKSideDrawerController is created and set up as rootViewController.

    The TKSideDrawerController is initialised with the content of my main UserVC. Everything functions as desired, except I am unable to respond to any clicks on SideDrawerItems as the relevant method is never called. My UserVC is set as a TKSideDrawerDelegate.

     

    I've been very impressed with the Telerik iOS UI tools so far, but this problem has been very frustrating!!!
  2. Adrian
    Admin
    Adrian avatar
    167 posts

    Posted 23 Nov 2015 Link to this post

    Hi, Cameron,

    Thank you for contacting us.

    Currently we are not able to reproduce such issue. The correct method signature is sideDrawer:didSelectItemAtIndexPath:. Could you please confirm that this is the delegate method you are trying to handle selection in? If yes could you please send us a sample project where the issue occurs so I could investigate it further and give you a proper solution?

    I am looking forward to your reply.

    Regards,
    Adrian
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. DevCraft banner
  4. Cameron
    Cameron avatar
    5 posts
    Member since:
    Nov 2015

    Posted 23 Nov 2015 in reply to Adrian Link to this post

    Hi Adrian -

     

    Thanks for the response - since I wrote my post, I have tried to get a simpler project working which solely uses the SideDrawer example given on the Telerik site :http://docs.telerik.com/devtools/ios/SideDrawer/overview

     

    I have had no success with this either... Perhaps there is an issue with the version of Xcode I'm using or something else weird!!!

     

    To give you specifics:

        

     

     

  5. Cameron
    Cameron avatar
    5 posts
    Member since:
    Nov 2015

    Posted 23 Nov 2015 Link to this post

    I am now running a test project, which has ViewController class + AppDelegate.

    The selection method is never called when SideDrawer items are clicked, but the SideDrawer is dismissed.

     Running Xcode 7.0.1 but don't think that is the problem.

  6. Answer
    Adrian
    Admin
    Adrian avatar
    167 posts

    Posted 23 Nov 2015 Link to this post

    Hello, Cameron,

    In the provided screenshot seems like the view controller where you want to handle the item tap is not set as delegate to the side drawer. You should first set the side drawer's delegate property to be able to handle the tap in the sideDrawer:didSelectItemAtIndexPath: method:
    - (void)viewDidLoad
    {
        //...
        self.sideDrawer.delegate = self;
        //...
    }

    I hope this helps. If you need further assistance do not hesitate to write again.

    Regards,
    Adrian
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  7. Cameron
    Cameron avatar
    5 posts
    Member since:
    Nov 2015

    Posted 23 Nov 2015 in reply to Adrian Link to this post

    Ahhh - thank you. It had to be something silly like that!!

    Thanks for your help.
  8. Adrian
    Admin
    Adrian avatar
    167 posts

    Posted 23 Nov 2015 Link to this post

    Hello, Cameron,

    I am glad that I could help. If you have further questions I will be glad to assist.

    Regards,
    Adrian
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  9. Sam
    Sam avatar
    12 posts
    Member since:
    Sep 2015

    Posted 01 Jan in reply to Adrian Link to this post

    thank you! i had the same problem and tried most of the same troubleshooting and this is what fixed it for me as well
Back to Top
DevCraft banner