Send a download invitation to a contact
Before you begin: Make sure you have
completed the task,
Register your
application with the BlackBerry Messenger pPlatform, and that the class
that displays the
MyBBMInviteScreen screen passes in a reference to the
application's associated
BBMPlatformContext object into the screen's contructor.
Code sample: Sending a download invitation to a contact
The following code sample assumes that the class that displayed the MyBBMInviteScreen has passed a reference to the application's associated BBMPlatformContext object into the MyBBMInviteScreen constructor.
import net.rim.blackberry.api.bbm.platform.*;
import net.rim.blackberry.api.bbm.platform.service.*;
import net.rim.device.api.ui.component.*;
public class MyBBMInviteScreen
{
public MyBBMInviteScreen(BBMPlatformContext platformContext)
{
MessagingService messagingService = platformContext.getMessagingService();
messagingService.sendDownloadInvitation();
}
}
Next topic: Send a join invitation to a contact
Previous topic: Code sample: Starting a BBM Chat