0

Working on the first swift app, and stuck in "share extension". Trying to share a phone number from recent calls log to an app for background task.

Thought to do it in this way, once user enter profile of a number from recent call log:

Will see the icon of my app:

Now want to get the phone number and the country code to do that task, current code is:

class ShareViewController: UIViewController {
    override func viewDidLoad() {
        // Want to get selected phone number only and print it on the console for testing
        print("Test\n")
    }
}

How to do that?

Thanks in advance

shallowThought
  • 19,212
  • 9
  • 65
  • 112

1 Answers1

0

Your App's icon is used. From Apples documentation:

In iOS, a custom Action extension uses a template image version of its containing app’s icon, which you must provide.

iOS Share extensions automatically employ the containing app’s icon. If you provide a separate icon in your Share extension target, Xcode ignores it. For all other app extension types, you must provide an icon that matches the containing app’s icon.

Community
  • 1
  • 1
shallowThought
  • 19,212
  • 9
  • 65
  • 112