darthcalis
Registered User.
- Local time
- Today, 12:26
- Joined
- Mar 20, 2012
- Messages
- 17
Hello,
Just wondering if I'm missing something obvious.
I have an unbound attachment field on a report which I use to display a company logo. The logo is a bmp file stored as an attachment in the database so that the client can change it any time they wish.
The code fires in the OnFormat event of the page header of the report. Problem is how to display the logo. This code works fine:
...where modUtils_GetDBDir() is getting the DB directory for me. But I would think there is a way to just display the logo from within the database, without having to resort to specifying the file? I have tried this:
...but I keep getting an error telling me the file isn't a DIB file! Tbh, I never heard of a DIB before today.
Do I have to convert my BMP to a DIB? Seems odd to me...think I must be missing something.
Emilio
Just wondering if I'm missing something obvious.
I have an unbound attachment field on a report which I use to display a company logo. The logo is a bmp file stored as an attachment in the database so that the client can change it any time they wish.
The code fires in the OnFormat event of the page header of the report. Problem is how to display the logo. This code works fine:
Code:
Me.attLogo.PICTURE = modUtils_GetDBDir() & "\Icons\" & rstLogo!FileName
...where modUtils_GetDBDir() is getting the DB directory for me. But I would think there is a way to just display the logo from within the database, without having to resort to specifying the file? I have tried this:
Code:
Me.attLogo.PictureData = rstLogo!FileData
...but I keep getting an error telling me the file isn't a DIB file! Tbh, I never heard of a DIB before today.

Do I have to convert my BMP to a DIB? Seems odd to me...think I must be missing something.
Emilio