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

Posts: 16
Registered: ‎07-28-2010
My Device: Bold 9700
My Carrier: Vodafone

File name for SupportAttachmentPart

I've implemented a sendMessage handler to intercept outbound email messages, I'm using some sample code from the docs to transverse the Message object and break it down into its seperate parts. 


When I find a "SupportedAttachmentPart" I need to access the attached file I want to get to the file name of the attachment too, for an attached image this is typically:




This fine as I can parse out the filename part. However if the image resize option is used during attachment the file name is:




I have checked both "getName" and "getFIlename" methods and both return the .tmp name as above. 


Is there a way to get the real filename from the SupportedAttachmentPart object during sendMessage processing?





// John Goodyear