Re: Outlook 2007 automatically renaming .GIF image to .PNG



Problem solved.

Caused by two things:

1) The signature included VML, which I hadn't expected and so wasn't being
correctly parsed. The <v:imagedata /> tag was not having the image's CID
set. When OL2007 displayed the message, it rendered the VML and therefore
wouldn't match the image to my attachment correctly.

2) When the message was sent, Outlook for some reason replaced the missing
attachment with a 'blank' image001.png. Without realising the VML issue was
occuring, this caused me to think it was modifying my original image.

Since I couldn't find any info on this issue elsewhere, perhaps this might
help someone in future.

Ben

"BenM" <nospam.flexibull@xxxxxxxxxxxxxxxx> wrote in message
news:O1$zxNyVIHA.5508@xxxxxxxxxxxxxxxxxxxxxxx
FWIW,

As a possible reason, I find that Outlook 2007's image compression is
turned on. For some reason I can't turn it off.

1) I create a new temporary message with an inline image in the signature.
2) I right-click select the image, click Picture Tools / Compress
Pictures.
3) From Options... I clear Automatically perform basic compression.
4) I click OK / OK and close the message.

If I repeat the procedure, in Step 3, Automatically perform basic
compression is still ticked. The GIF I'm attaching to my message is still
being (it seems) converted to a PNG.

If I create a message in Outlook, the message shows the logo I want to
use. Outlookspy shows my signature's inline image is a GIF with
PR_ATTACH_SIZE = 2322.

If I create my message via extended MAPI, it is now a PNG with size 382,
and the image appears blank (correct screen dimensions, but solid white).

My guess is the problem is, therefore, somehow related to automatic
compression.

Any ideas?

Ben

"BenM" <nospam.flexibull@xxxxxxxxxxxxxxxx> wrote in message
news:eG%23XdbnVIHA.6140@xxxxxxxxxxxxxxxxxxxxxxx
I am experiencing an interesting feature in that Outlook 2007 appears to
rename my .gif attachment to .png, making the content undisplayable. The
same code works without issue against Outlook 2003. Does anyone know if
this is intentional and documented?

Some (abbreviated!) background, for the curious:

I have written a module that tests so far perfectly against Outlook 2003
and non-Outlook systems. The module finds the users signature files via
the registry, parses the signature, and links in the referenced attached
images.

I am now testing this on a shiny new machine with Office 2007 installed
as part of tests against other versions of Office.

I created a signature in Outlook 2007, and attached a .gif image to it.

My program found the signature file, parsed it, attached the referenced
.gif image, and then assembled the combined message and signature content
in the PR_HTML message property.

The result:
* The image doesn't display (at all) in the sender's Outlook, I just get
a small X (image missing) icon.
* In gmail, it shows the image as a white rectangle, and an attachment
with the name image001.png.
* In the receiving Outlook (2003), the attachment doesn't appear (hidden)
and a white rectangle appears in the message where it should have been.
* In outlookspy, I see that the CID in PR_ATTACH_CONTENT_ID and PR_HTML
match, however they have been changed (they were something like
image001.gif@xxxxxxxxxxxxxxxx and are now something like
image001.png@xxxxxxxxxxxxxxxx where 9 is my home-made uid, and 8 is
outlook's).
* If I send a test message through Outlook, the message arrives at the
destination as a .GIF and is displayed correctly.

If it helps, I can attach the html that I submit to PR_HTML, and the html
that Outlook seems to have changed it to.

Any thoughts will be much appreciated.

Cheers,

Ben





.



Relevant Pages

  • Re: SBS / outlook wierd image attachment / signature issue
    ... Hi, I have narrowed the issue down to the normal.dot and using word as an email editor, the image is not related to a signature being attached or not. ... Some of your client users will get attachment with image file when they ... Turn off third-party add-ins in Outlook ...
    (microsoft.public.windows.server.sbs)
  • Re: script to create signatures to all users
    ... Otherwise, I don't know why it's not working, only that using those registry values in that fashion is not supported by Microsoft. ... Author of Microsoft Outlook 2007 Programming: ... POLICY "Signature for new messages" ...
    (microsoft.public.outlook.program_vba)
  • Re: script to create signatures to all users
    ... some of our cients' outlook 2003 don't allow for the new signature to be ... POLICY "Signature for new messages" ... create your .html file and store it in there. ...
    (microsoft.public.outlook.program_vba)
  • Re: Marquee tag in Outlook 2003 and fancy signatures
    ... this is what I'M wanting to do as well. ... Teach Yourself Outlook 2003 in 24 Hours ... signature for marketing dept, which love having things like that. ... I've receive an email message with the scrolling text in the signature ...
    (microsoft.public.outlook)
  • Re: Insert a Signature via Code
    ... Author of Microsoft Outlook 2007 Programming: ... signature was named given that multiple ... The solution that I'm implementing invovles building a custom ... Signatures is that when the code runs, any hyperlink is converted to read ...
    (microsoft.public.outlook.program_vba)