Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We are running a piece of software called Exclaimer which sets a standard template for email signatures and grabs some details from Active directory, like Contact numbers and title.

I need to add a QR Code to the signature but it will need to be different for 50 + people, so I cannot use the standard template.

I could create a template for everyone individually, but I would like to know if there is a more efficient way of doing this?

share|improve this question
Do you already have images of your QR codes or do you want Exclaimer to generate the QR codes on the fly? I'm guessing the latter, in which case I don't think Exclaimer does that natively. You might want to get on to Exclaimer and make a feature request. If you have separate QR codes for everyone as images, you might be able to hack something together but it won't be dynamic, which kind of defeats the point of having Exclaimer in the first place. – Ben Pilbrow Feb 14 '12 at 13:37
Thank you, I have spoken to Exclaimer and they said "If you are able to populate an Active Directory field with the QR code then you can use this field in your template". When asking them how to do this, they do not know. Thank you for your advice. – Matt Feb 14 '12 at 14:22
So do you have the QR codes pre-generated as image files? – Ben Pilbrow Feb 14 '12 at 14:29
Not yet but that will be the plan. – Matt Feb 14 '12 at 14:33
Cool - I'm in the middle of something right now, but I have a plan and I'll post an answer later today. – Ben Pilbrow Feb 14 '12 at 14:41
up vote 5 down vote accepted

Since you have the images pre-prepared, you should be able to bring them in using a built in Exchange 2010 PowerShell cmdlet or a free product from Exclaimer themselves. Bear in mind though that (as I'm sure you're aware) this does kind of defeat the object of Exclaimer, since if somebody gets married or changes their phone number the QR code image will have to manually be changed.

These pictures will be stored as raw bytes in Active Directory, so there are a few things you should bear in mind.

  • The ideal size of a picture is 96x96 pixels
  • The size of your Active Directory database will increase and as a consequence will take longer to back up
  • This is just another attribute on each user object, so populating it will cause replication traffic between Domain Controllers. Maybe do it in the evening when the extra network traffic won't be noticed

On the Exchange blog post on the subject, they say thumbnails for 10,000 users would add around 100 MB to your Active Directory database, but obviously your mileage will vary. That blog post is a must-read by the way and contains loads of useful information about this feature.

To import a single photo into Active Directory you can use the following cmdlet. I don't think it will be too hard to wrap this up in a Get-Mailbox | Import-RecipientDataProperty ... loop (my Exchange VM is busted at the moment, or I'd have whipped one up for you).

Import-RecipientDataProperty -Identity <Username> -Picture -FileData ([Byte[]]$(Get-Content -Path "C:\GalPhotos\Some Photo.jpg" -Encoding Byte -ReadCount 0))

Alternatively, just use the freebie from Exclaimer which I linked to above.

Note that both the cmdlet and the Exclaimer utility will populate the field which Outlook 2010 uses as its picture, so the QR codes will start showing up in people's Outlook. That's up to management whether they want that, and if they don't you can write a PowerShell script to store the data in one of the other picture attributes which Exchange/Outlook doesn't use (jpegPhoto maybe).

Once your pictures are in Exchange, you can add a field in each Exclaimer disclaimer you want and Exclaimer should do all of the decoding of the raw bytes into a picture.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.