×

Discussion Board

Results 1 to 7 of 7
  1. #1
    Registered User
    Join Date
    Aug 2009
    Posts
    22

    5800 local files

    Hi, I have this piece of code:

    //lee el fichero y lo mete en el DOM
    QFile f("c:/fichaAPI.xml");
    QFile nuevo("c:/nuevo.txt");
    nuevo.open(QIODevice::WriteOnly|QIODevice::Text);
    if(!f.open(QIODevice::ReadOnly | QIODevice::Text)){
    qDebug("imposible to open the file");
    } else qDebug("open:-)");

    To read a xml from a local file. It works on the simulator but do not find the file fichaAPI.xml in the device :-?
    I create the "nuevo" file to be sure of the directory. I do not know if it is created or not (not in c:\ when working in the device).
    If I show the current path in the device (using QDrive and a label) it is c:/private/ee7f... I can see in the explorer c:/Private (connecting the phone as a mass stroge)but NOT the last folder (ee7f...)....
    IT'S SO FRUSTRATING!!!
    Where is everybody??

    please help

  2. #2
    Super Contributor
    Join Date
    Nov 2009
    Location
    Minnesota, USA
    Posts
    3,209

    Re: 5800 local files

    Drop the "C" from the file specification (just use ":/fichaAPI.xml") if you want to locate the file in the application's private directory.

  3. #3
    Registered User
    Join Date
    Aug 2009
    Posts
    22

    Re: 5800 local files

    Hi Danhicksbyron, thanks for the reply, but the point is different, maybe I didn't explained well.
    I Wrote the xml and I copyed it to the phone, so the .sys can read it. BUT the sys never finds it despite I explicty put the whole path (and avoid the private).
    If I try to create a file ( in c:\) later it is not where it is suposed to be. Only in the device cause in the simulator it works great.

    I hope now it is more clear
    Thanks again

  4. #4
    Super Contributor
    Join Date
    Nov 2009
    Location
    Minnesota, USA
    Posts
    3,209

    Re: 5800 local files

    Yeah, I'm not finding files where one would expect them on the N97 either. There's something going on that isn't well-documented.

  5. #5
    Super Contributor
    Join Date
    Nov 2009
    Location
    Minnesota, USA
    Posts
    3,209

    Re: 5800 local files

    I just figured out that the visible portion of the C: drive, as viewed by Windows Explorer of the File Manager, is located in "C:/Data" (at least on the N97). This means that you need to pre-pend "C:/Data/" to any file reference on the C: drive. (Not sure about the other drives, but I suspect the same.)

  6. #6
    Regular Contributor
    Join Date
    Sep 2008
    Posts
    286

    Re: 5800 local files

    c:\data is the directory what PC/Ovi-Suite sees. Idea is the same as in My Documents in MS Windows.
    You are not supposed to see or get your hands to anything other than document files.

    Your applications configuration files should be put to c:\system\data if global or c:\private\<SID> if not usefull to other apps.

    Problem is that you need to have allFiles signed filebrowser to see them and use sis files to deploy and your own custom app to extract (or use the browser to copy them over to c:\data and then Ovi-suite).

    One more thing about c:\data , that directory is being indexed all the time for new media files so you want to avoid writing anything volatile into it.

  7. #7
    Registered User
    Join Date
    Aug 2009
    Posts
    22

    Re: 5800 local files

    Now it works ! :_)
    thanks th both

Similar Threads

  1. Disabled security check when reading/writing in local files
    By dave33 in forum Mobile Java Networking & Messaging & Security
    Replies: 11
    Last Post: 2010-04-23, 12:26
  2. Replies: 0
    Last Post: 2009-08-12, 10:13
  3. missing header files from FP1 SDK & Plug-ins.
    By ruchirvasavada in forum Symbian Tools & SDKs
    Replies: 1
    Last Post: 2008-09-08, 20:54
  4. Problem N95: listing local files
    By R.Guerra in forum Mobile Java General
    Replies: 2
    Last Post: 2008-08-29, 16:40

Posting Permissions

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