Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Contributor
Posts: 2
Registered: ‎05-07-2012
My Device: Torch 9810
My Carrier: T-Mobile

How to get currently selected appointment and current user context in an appointment extension module?

Hi, we are trying to build an extension to default calendar appointments in RIM that can show some additional details for a given meeting based on the current user and the current appointment details. However when our extension module is invoked from the appointment details menu, we do not get the appointment handle or any other context handle that can provide us the information about the user and the appointment itself.

 

Any ideas on how this information can be accessed? If this is not possible using the Java APIs, could you please let us know if it is supported in other platforms (eg HTML5?)?

 

Many thanks!

 

Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: How to get currently selected appointment and current user context in an appointment extension module?

I assume that you are using ApplicationMenuItem and ApplicationMenuItemRepository?

 

This seems to work fine in my experience. You say you are not getting the context - what are you getting, exactly? Can you post some code?

Highlighted
New Contributor
Posts: 2
Registered: ‎05-07-2012
My Device: Torch 9810
My Carrier: T-Mobile

Re: How to get currently selected appointment and current user context in an appointment extension module?

I got it working. Thanks for indicating that ApplicationMenuItemRepository works and provides the context.

I was not using Run(Object context) which carries event context in this specific case. I am using following:
public Object run(Object context)
{
if (context instanceof Event)
{
try
{
Event evt = (Event) context;