Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Jun 2009

    Accessing resource file at run-time

    My app needs to access/load resource files (image or xml) at run-time.
    QFile file("./config.xml");

    I just want to know where should I put these resource files in for the emulator WINSCW. I have tried to copy resource files into the launch folder:
    But, it seems dosen't work.

    Same kind of question is how to create package (sisx) with additoinal resource files in?

    Any help? thanks
    Last edited by shudder; 2009-06-11 at 10:34. Reason: format

  2. #2
    Super Contributor
    Join Date
    Oct 2007
    જુનાગઢ - India

    Re: Accessing resource file at run-time

    Welcome to Forum Nokia DiBo.

    QDir::currentPath() returns the absolute path of the application's current directory, private path. so it is better to place files at private path on device, and then get path using QDir::currentPath().

    For emulator ..\epoc32\winscw\c\private\<UID of app> is the current directory for application. so put your files there to access in emulator.

  3. #3
    Registered User
    Join Date
    Jun 2009

    Re: Accessing resource file at run-time

    Great help! thanks

  4. #4
    Nokia Developer Expert
    Join Date
    Jun 2008

    Re: Accessing resource file at run-time


    You can use DEPLOYMENT variable in the .pro file to include files to the sis package.
    symbian: {                           
        addFiles.sources = logo.bmp
        addFiles.path = .
        DEPLOYMENT += addFiles
    That will add the following line into the generated pkg file

    "c:\symbian\Carbide\workspace\Test\logo.bmp"    - "!:\private\eff58179\logo.bmp"
    For details see:

    Best Regards,
    Last edited by isalento; 2009-06-12 at 11:17. Reason: link fixed (hopefully)

Similar Threads

  1. MBM image is not found
    By tamhanna in forum Symbian
    Replies: 14
    Last Post: 2009-04-20, 12:44
  2. How to edit resource file (.rss) in CW 3.1
    By madsum in forum Carbide.c++ IDE and plug-ins (Closed)
    Replies: 8
    Last Post: 2009-01-16, 15:00
  3. Replies: 1
    Last Post: 2005-05-26, 14:22
  4. nokia 7210 modem via IR doesn't work !
    By oussamaaiadi in forum PC Suite API and PC Connectivity SDK
    Replies: 1
    Last Post: 2003-03-06, 10:46
  5. Replies: 0
    Last Post: 2002-06-10, 12:24

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts