skip to Main Content

When I create a sample iMessage app project and run it on my device, it consistently displays the error message ‘Error creating the CFMessagePort needed to communicate with PPT.’ Additionally, when I attempt to print the value of ‘activeConversation,’ it always returns ‘nil.

I am expecting that activeConversation shouldn’t be nil.

2

Answers


  1. Chosen as BEST ANSWER

    I was actually developing an app in which I wanted to send a message from the app when a user taps on a button. I intended to send a message directly from my extension, but I encountered an error where 'activeConversation' returned 'nil,' even though I expanded the screen and the message wasn't being sent. I resolved this issue by removing navigation controller from the initial view controller. When I add navigation controller to initial view controller it always gives me nil value of activeConversation.


  2. Also if you specify your app to be a Sticker app in the info.plist using

    <key>MSSupportedPresentationContexts</key>
    <array>
      <string>MSMessagesAppPresentationContextMessages</string>
      <string>MSMessagesAppPresentationContextMedia</string>
    </array>
    

    and not just a plain Messages app, activeConversation will return nil

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search