0

I have a playercontroller view..in this view I am playing selected poem from an array which have collection of my poems.

Now when playing any poem I want to take control to push, play, next, previous and volume control from Apple Watch.

Here is my code for the iPhone which plays a poem:

if(btnClick == 1) {

    self.lblTitle.text=[titles objectAtIndex:0];
    [self.imgpoem setImage:[poemImages objectAtIndex:0]];

    NSString *songurl=[poemcollection objectAtIndex:0];
    [self playselectdpoem:songurl];
}

How can I add this functionality to the WatchKit Extension to control all the things?

iGatiTech
  • 2,306
  • 1
  • 21
  • 45
dilip
  • 163
  • 8

1 Answers1

0

To control the iPhone app from the watch, you have to use the openParentApplication method. You can take a look HERE, how to implement this method.

The same thing as sending data is to send a signal to the iPhone to do something - in your case, to Pause, Play, Stop ect.

Community
  • 1
  • 1
Dejan Skledar
  • 11,280
  • 7
  • 44
  • 70