locked
Problem with share jpg images RRS feed

  • Question

  • Hi,

    in my application I want to share some information with html, so that the mail app can use it.
    In the shared content there will be both images and text.
    I successfully share the content in html, but I have problems with the images:
    all my images are jpg type and so they have small size, but when I put them in the ResourceMap using the RandomAccessStreamReference they are exported in png.
    And for this reason, the email become too big and is very slow to send.

    is there a way to keep the image as jpg? Project

    I uploaded in my skydrive a small project that reproduce the problem: Project Link
    in the project there is a file called photo.jpg that is very small in size (82kb), but when you share it using the mail app, it is sent as png and is about  1400kb!


    i also tried to use the setbitmap option and share the image in onenote, and there is the same problem.

    Thursday, August 1, 2013 10:03 AM

Answers

  • You cannot control how the share target handles the shared items.

    If you examine the sharedResourceMap in the Share Target sample you will see that it is a JPG there. It appears that the Mail app or server may be converting it to a PNG.

    --Rob

    Friday, August 2, 2013 1:35 AM
    Moderator

All replies

  • You cannot control how the share target handles the shared items.

    If you examine the sharedResourceMap in the Share Target sample you will see that it is a JPG there. It appears that the Mail app or server may be converting it to a PNG.

    --Rob

    Friday, August 2, 2013 1:35 AM
    Moderator
  • You cannot control how the share target handles the shared items.

    If you examine the sharedResourceMap in the Share Target sample you will see that it is a JPG there. It appears that the Mail app or server may be converting it to a PNG.

    --Rob

    yes you're right.

    so there is a problem in the mail app, there is no reason for that to convert it in png (and so with a very big increase of the size). With my application, a small email of about 100 kb will be converted in an email of about 2Mb. How can I solve it?

    This problem is present also in the new version of mail app in Windows 8.1 (in the preview this problem is still there)?

    Friday, August 2, 2013 8:33 AM
  • This isn't an issue in your app. There is nothing your app can do to change it.

    Your app cannot control which share target the user chooses or how that target uses the data.

    --Rob

    Friday, August 2, 2013 2:51 PM
    Moderator
  • This isn't an issue in your app. There is nothing your app can do to change it.

    Your app cannot control which share target the user chooses or how that target uses the data.

    --Rob


    I know isn't an issue in my app, but is an issue FOR my app because my users can't share item by email because the images are too big.
    I don't think this is a right behaviour of mail app. is this a known problem that will be solved in 8.1?
    Friday, August 2, 2013 3:19 PM
  • As you noted in your previous post, this behavior is present in the Mail app in the Windows 8.1 Preview. I cannot comment on future releases, but I'll note it to be investigated for future versions of the Mail app.

    --Rob

    Friday, August 2, 2013 3:33 PM
    Moderator