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: 5
Registered: ‎06-18-2014
My Device: 9930
My Carrier: No provider

ApplicationMessage no title in message preview

Hello,

I am trying to add a custom ApplicationMessage to my app, however, when clicking the notification the title area is blank.

If someone can tell me what I am missing that would be great.

Thanks,

 

Developer
Posts: 17,011
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: ApplicationMessage no title in message preview

not without your code
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Highlighted
New Contributor
Posts: 5
Registered: ‎06-18-2014
My Device: 9930
My Carrier: No provider

Re: ApplicationMessage no title in message preview

[ Edited ]

Can you advise me to which peice you need?

Here is my ApplicationMessage implimentation 

 

    class MyApplicationMessage implements ApplicationMessage 
    {
        private String message_;
        private String subject_;
        private long timestamp_;

        public MyApplicationMessage(String message, String subject) {
            message_ = message;
            subject_ = subject;
            timestamp_ = new Date().getTime();
        }

        public String getContact() {
            return subject_;
        }

        public Object getCookie(int cookieId) {
            return null;
        }

        public Object getPreviewPicture() {
            return null;
        }

        public String getPreviewText() {
            return message_;
        }

        public int getStatus() {
            return ApplicationMessage.Status.UNOPENED;
        }

        public String getSubject() {
            return message_;
        }

        public long getTimestamp() {
            return timestamp_;
        }

        public int getType() {
            return 0x01;
        }
    }