Trust ID PBCEX logo 300x102

Image storage in MS Access using OLE objects

10 years 9 months ago
Sergio Agostinho
Posts: 508
Topic Author
Image storage in MS Access using OLE objects #1197
Sometimes when connecting CardExchange to an existing MS Access database is not possible to see the images previously stored in a CardExchange photo object.
This happens because the OLE object has an header that needs to be handled by CardExchange to show the image, for bitmap images this header has a fixed size but it can change depending of the language of the operating system that you're using. For an English system this size is 78 bytes but for a Spanish one this size will be 88 bytes.
There is an option in CardExchange.ini file named "OleHeaderLength" where is possible to define this value, according with the values below:

There is some sort of formula to calculate this, is like 78 + ( length(bitmap type description for your language) - 12).
You can find in the attached zip file an excel to do this calculation, just type your bitmap file description in the field specified for that and you wil get the size to change this setting in CardExchange.ini.
[attachment=0:1razwppw]<!-- ia0 --><!-- ia0 -->[/attachment:1razwppw]
Please feel free to add new header sizes to this topic.

With best regards
Sergio Agostinho