Board index » delphi » graphics images (BMP or JPEG) to BMP
Paul Nicholls
![]() Delphi Developer |
Mon, 24 Dec 2001 03:00:00 GMT
graphics images (BMP or JPEG) to BMP
I have written a auto desktop background updating program using Delphi
3(Standard) which takes the graphic image pointed to by filenames in a TListBox, places it in a 'BGWizard.bmp' file in the windows directory and makes the desktop bitmap become this graphic. The problem is, even after I registered JPEG files with TImage (after creating a JPEG package including the .pas files from the CD) I get a EInvalidGraphic with message 'Unknown picture file extension (.jpg)' error message at GetWindowsDirectory(wd, 63); in the code below. If the file is a BMP graphic, I seem to get a Access Violation error I know the registration worked ok because if I place a TImage on a form and Var SystemParametersInfo(SPI_SETDESKWALLPAPER,SPI_SETDESKWALLPAPER,PChar(S),SPI -- |