A Sharing Panel allows the application to share a piece of text, a URL, or a picture with any registered system service or app.
Name As String
The name of the control.
Handle As Ptr
The a handle to the underlying native OS control.
Displays the sharing panel to the user, allowing them to share the passed picture.
A NilObjectException is raised if pic is Nil.
Share a picture:
MySharingPanel.SharePicture(myPic, Self, Me)
Displays the sharing panel to the user, allowing them to share the passed text.
Share text from a Text Area:
MySharingPanel.ShareText(DescArea.Text, Self, Me)
Displays the sharing panel to the user, allowing them to share the passed URL.
An InvalidArgumentException is raised if the url parameter is not a valid URL construct.
Share a URL:
MySharingPanel.ShareURL("http://www.wikipedia.org", Self, Me)
Called when the sharing panel has been cancelled.
Called when the control's layout is closing.
Called when the the sharing panel closes because the user completed sharing something.
Called when the control's layout is opening.
This is where you typically put initialization code.
This example in the Opening event of a label sets its text to "Hello":
Me.Text = "Hello"
By default, Xojo provides a default message that will appear when the user is asked for permission to access their photo library. If you wish to customize this message, go to Build Settings in the Navigator, click on iOS then click on the Advanced tab in the Inspector. Enable Photo Access then click the Options button.
Mobile projects on all supported mobile operating systems.