×

Discussion Board

Results 1 to 10 of 10

Thread: Saving data

  1. #1
    Regular Contributor
    Join Date
    Apr 2008
    Posts
    54

    Saving data

    Hi ,
    I'm developing an a[[lication in Symbian and I want to save some data(Of the App.) in the drive.
    There is options (Exceps regular read/write from file) to do it ? (i.e. DB , Save objects to file like java ,or Registery).

    Best regrads ,
    Pood

  2. #2
    Registered User
    Join Date
    Dec 2005
    Posts
    1,236

    Re: Saving data

    You could use Database to store your information.
    Regards,
    Sriky

  3. #3
    Regular Contributor
    Join Date
    Apr 2008
    Posts
    54

    Re: Saving data

    Quote Originally Posted by sriky27 View Post
    You could use Database to store your information.
    Thanks , The question is which DB (If you have the name of API for the DB) and If it is worthwhile to do it for small amount of data ?

  4. #4
    Registered User
    Join Date
    Jun 2006
    Location
    India
    Posts
    1,043

    Re: Saving data

    Hi,
    You could use any other way to store your data but I guess you will require to use RFile class to achieve it. So Read/Write methods are still valid methods for your case.
    Maximus
    S60 Developer
    Impossible is nothing

  5. #5
    Registered User
    Join Date
    Dec 2005
    Posts
    1,236

    Re: Saving data

    Hi,

    You could use RDbNamedDatabase here in the following link there is a sample implementation http://wiki.forum.nokia.com/index.php/Database_Example
    Regards,
    Sriky

  6. #6
    Registered User
    Join Date
    Jun 2006
    Location
    India
    Posts
    1,043

    Re: Saving data

    Quote Originally Posted by poodk View Post
    Thanks , The question is which DB (If you have the name of API for the DB) and If it is worthwhile to do it for small amount of data ?
    Hi,
    If you want your data to be secure (by not allowing other application to access your data) then you can store your data in your private UID folder.This will prevent other application to have access to your data. Only your application will have access to the data.
    Maximus
    S60 Developer
    Impossible is nothing

  7. #7
    Regular Contributor
    Join Date
    Apr 2008
    Posts
    54

    Re: Saving data

    The problem to use in RFile that I want to save data that after it i'll need to parse it (From the file).
    What i want is to load and save different types (Like TTime , Tbuf , etc) on the device without need to parse it.If I want want to save only text , I will use file direct probably.

  8. #8
    Registered User
    Join Date
    Dec 2005
    Posts
    1,236

    Re: Saving data

    Hi poodk,

    You could use RDbNamedDatabase to store TTime and Tbuf check out the link I have given and also check out RDbRowSet public api's.
    Regards,
    Sriky

  9. #9
    Regular Contributor
    Join Date
    Apr 2008
    Posts
    54

    Re: Saving data

    Thanks , that what I search

  10. #10
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,750

    Re: Saving data

    DB is a bit overkill for this purpose.
    If you have a T-class, say
    Code:
    class TAdvertisement
    {
    public:
        TBuf<20> iWare;
        TBuf<200> iDescription;
        TInt iPrice;
        TTime iDeadline;
    };
    and you want to save or load it, just write
    Code:
    // 'ad' is a TAdvertisement, 'file' is an RFile
    TPckg<TAdvertisement> adpack(ad);
    file.Write(adpack);
    // or file.Read(adpack); and the result immediately appears in 'ad'
    TPckg (and TPckgBuf) is a packaging descriptor, it wraps your structure into a 8-bit descriptor which can be directly written/read to/from a file without text-conversion/parsing.

Similar Threads

  1. Replies: 2
    Last Post: 2008-07-03, 15:29
  2. Saving Data on Dialog
    By amitaggarwal in forum Symbian
    Replies: 2
    Last Post: 2004-09-01, 04:46
  3. Problems with client/server data transfer
    By wilse in forum Symbian
    Replies: 1
    Last Post: 2004-08-03, 16:14
  4. Saving downloaded data
    By ins0mnia in forum Mobile Java Networking & Messaging & Security
    Replies: 6
    Last Post: 2003-08-31, 09:56
  5. Saving data from Settings Listbox
    By ashbhatia in forum Symbian User Interface
    Replies: 0
    Last Post: 2002-11-20, 09:19

Posting Permissions

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