Hi: After i add "LeaveIfError" ,emulator has the "system error -34" And i think in device ,it will show the same error.... ########################################## #define TEST_MBM _L("\\system\\apps\\test\\WallPaper.mbm") TFileName iPaperName; TBuf16<KMaxFileName> igpName16(TEST_MBM); iPaperName = igpName16; User::LeaveIfError(AknsWallpaperUtils::SetIdleWallpaper( iPaperName , NULL , 0 , 0 )); ########################################## Do You know what's wrong with "filename"? Thanks.Thanks again.
First you have to qualify a full path including drive letter probably? #define TEST_MBM _L("C:\\system\\apps\\test\\WallPaper.mbm")
The other problem might be that it doesn't work with MBM. MBM is a multi bitmap file and the API doesn't contain a parameter to identify which icon to use so I assume it will not work with MBM. Try using a JPG for example.
Forum posts: 37
take a look at aknswallpaperutils.h (only 3rd edition). There you can set the wallpaper. But thats more or less all you can do with the idle screen
Regards,
have fun...
Rayko Enz
www.sic-software.com
Forum posts: 28
i'll have a try.
In SDK 3rd,i found
static IMPORT_C TInt AknsWallpaperUtils::SetIdleWallpaper
Forum posts: 28
I have some problem again. when use this:
AknsWallpaperUtils::SetIdleWallpaper( filename , NULL , 0 , 0 );
Function retrun -34
Is "filename " Error?or some format error maybe....
Do You Have Sample Code about this?
Thanks a lot...
Best Regards
Silicon
Forum posts: 37
User::LeaveIfError(AknsWallpaperUtils::SetIdleWallpaper(filename, NULL));
In which situation do you call that code? Do you tried it on emulator? Probably it doesn't work in emulator. Try on device.
filename should be the full name and path to your e.g. JPG
have fun...
Rayko Enz
www.sic-software.com
Forum posts: 28
After i add "LeaveIfError" ,emulator has the "system error -34"
And i think in device ,it will show the same error....
##########################################
#define TEST_MBM _L("\\system\\apps\\test\\WallPaper.mbm")
TFileName iPaperName;
TBuf16<KMaxFileName> igpName16(TEST_MBM);
iPaperName = igpName16;
User::LeaveIfError(AknsWallpaperUtils::SetIdleWallpaper( iPaperName , NULL , 0 , 0 ));
##########################################
Do You know what's wrong with "filename"?
Thanks.Thanks again.
Forum posts: 37
#define TEST_MBM _L("C:\\system\\apps\\test\\WallPaper.mbm")
The other problem might be that it doesn't work with MBM. MBM is a multi bitmap file and the API doesn't contain a parameter to identify which icon to use so I assume it will not work with MBM.
Try using a JPG for example.
BTW you can shorten your code like this:
_LIT(KWallpaperFilename,"c:\\system\\apps\\test\\WallPaper.jpg");
User::LeaveIfError(AknsWallpaperUtils::SetIdleWallpaper(KWallpaperFilename, NULL));
have fun...
Rayko Enz
www.sic-software.com
Forum posts: 28
And If WallPaper.mbm come from "CFbsBitmap::Save(TEST_MBM )"
As You said it will not work with MBM,I should trans MBM->JPG?
(close to the successÂ
Forum posts: 10
Hi,
Am also doing in the Same Way in 3rd edition to change the Wallpaper,
_LIT(KWallpaperFilename,"c:\\system\\apps\\test\\WallPaper.jpg");
TInt errorCode = AknsWallpaperUtils::SetIdleWallpaper(KWallpaperFilename, NULL);
The Wallpaper is not Changing and then the return errorcode is " KErrPermissionDenied -46 "
please tell me to solve this, i go thru Documentation, the Capabilities for "AknsWallpaperUtils" is None .... So, whats the Problem for this one ....
Please help to solve this ASAP ....
Thanks in Advance . . . . .
Forum posts: 28
Hi:
AknsWallpaperUtils use low capability .
The class usage in my project is below:
_LIT(KWallpaperFilename,"c:\\Data\\test\\WallPaper.jpg");
TInt iWP = AknsWallpaperUtils::SetIdleWallpaper( KWallpaperFilename,NULL , 0 , 0 );
And just " ReadUserData " in MMP file.
Try and good luck.
BR. Silicon
Forum posts: 10
Hi Silicon,
Thanks for your Reply ...
Am agree you Suggestion ...
The Strange thing is, I tried with only "ReadUserData " and the Same wallpaper function , but i got the errorcode " KErrPermissionDenied -46 "
I Added the "WriteDeviceData" and "ReadDeviceData" in .mmp file for try and i create the certification and tested, its working Fine now .....
Its behaving strangely ...
Am testing with "E61" ,