Discussion Board

Results 1 to 6 of 6
  1. #1
    Registered User baaluaanand's Avatar
    Join Date
    Mar 2009
    Posts
    13
    Hi,

    I have a problem in deleting a record store. I have done the following code to delete

    rs.closeRecordStore();
    RecordStore.deleteRecordStore("Test 1");

    but not able to delete, the following exception is thrown

    javax.microedition.rms.RecordStoreException: deleteRecordStore error: record store is still open

    Any one help me.

    Thanks in advance
    Baalu Aanand

  2. #2
    Regular Contributor vineetbillorey's Avatar
    Join Date
    Aug 2008
    Location
    Gurgaon, India
    Posts
    155
    can u pls give full code..??
    Vineet Billorey "The Great"

  3. #3
    Registered User baaluaanand's Avatar
    Join Date
    Mar 2009
    Posts
    13
    Here is the code i have used

    RecordStore rs = RecordStore.openRecordStore("Test", true);

    Here i opened and inserted some data. Then at last I have tried to delete the record store by using the following method.

    public void destroyRecord() {
    try{
    rs.closeRecordStore();
    RecordStore.deleteRecordStore("Test");
    }catch(Exception e)
    {
    e.printStackTrace();
    }
    }

    Thanks
    Baalu Aanand

  4. #4
    Regular Contributor vineetbillorey's Avatar
    Join Date
    Aug 2008
    Location
    Gurgaon, India
    Posts
    155
    u may have opened some other object used in the operation which was not closed, hence the recordStore is not closed.

    pls give full code
    Vineet Billorey "The Great"

  5. #5
    Nokia Developer Champion jitu_goldie's Avatar
    Join Date
    Sep 2008
    Location
    Noida, U.P.
    Posts
    1,330
    Hi,

    Please explain about exception comes if any at the time of deletion of recordstore.
    Also take care of opening and closing of recordstore. Suppose if u open recordstore 5 times then it is compulsory to close it 5 times. Means u have to close the recordstore equally to the number of openings of recordstore.

    Well its much better to close the recordstore just after use of it ie open , use and close.
    please check and reply.

    thanks,
    jitu_goldie..
    thanks,
    jitu_goldie..

    KEEP TRYING..

  6. #6
    Registered User baaluaanand's Avatar
    Join Date
    Mar 2009
    Posts
    13
    Thanks everyone.I have made a mistake of not closing the record store.Now its working fine

Similar Threads

  1. deleting a single record
    By dinoabz in forum Mobile Java General
    Replies: 3
    Last Post: 2009-03-23, 08:50
  2. Record live video On realphone Problem
    By gordon32 in forum Mobile Java Media (Graphics & Sounds)
    Replies: 4
    Last Post: 2007-03-30, 03:03
  3. Record Store vs JDBC. How to store data?
    By 180ºrevolution in forum Mobile Java General
    Replies: 0
    Last Post: 2004-09-17, 15:24
  4. 3650 & Record Store
    By basarim in forum Mobile Java General
    Replies: 4
    Last Post: 2003-12-10, 22:20
  5. Record Store problem
    By anandmanish in forum Mobile Java General
    Replies: 3
    Last Post: 2003-09-15, 10:30

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved