Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8248025
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T23:03:27+00:00 2026-06-07T23:03:27+00:00

I am trying to save some files on micro SDCard. To check the availability

  • 0

I am trying to save some files on micro SDCard. To check the availability of SDCard, I am using the following method;

private boolean isSdCardReady() {
    Enumeration e = FileSystemRegistry.listRoots();

    while (e.hasMoreElements()) {
        if (e.nextElement().toString().equalsIgnoreCase("sdcard/")) {    
            return true;
        }
    }
    return false;
}

Even if this method returns true, when I try to save files, it gives exception net.rim.device.api.io.file.FileIOException: File system is not ready.

What does this means? If SDCard is not available, then why its listed in FileSystemRegistry.listRoots()?

How can I make sure that SDCard is available for writing?

My development environment:

  • BlackBerry JDE Eclipse Plugin 1.5.0
  • BlackBerry OS 4.5
  • BlackBerry Bold with a 3G card
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T23:03:28+00:00Added an answer on June 7, 2026 at 11:03 pm

    Solved the problem. I was looking for “sdcard” while rootsEnum.nextElement().toString(); returns “SDCard”. Yeah, its case sensitive. Now, instead of using hard-coded “SDCard”, I’ve changed the above method to the following;

    private static String getSdCardRootDir() {
        Enumeration rootsEnum = FileSystemRegistry.listRoots();
    
        while (rootsEnum.hasMoreElements()) {
    
            String rootDir = rootsEnum.nextElement().toString();
    
            if (rootDir.equalsIgnoreCase("sdcard/")) {
                return "file:///" + rootDir;
            }
        }
    
        return null;
    }
    

    Using this, I got the root directory in its system defined case.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to save some files using C, with this code: sprintf(playerinput,%s,end); sprintf(fileloc,%s/.notend,getenv(HOME));
I'm trying to save some data to A file in android, I'm using herefor
I'm trying to save myself some coding time by taking advantage of using namespace
I am trying to upload some files using the multiple upload file field. The
I'm trying to parse some relative large xml-files using the standard sax parser in
I am trying to save some block coverage using an array of integers that
I'm trying to save some lookup table data out to a YAML file so
I'm trying to save a file in which I have some credentials. In order
I'm trying to save some data into an array but unfortunately all the data
I'm trying to save some UserControl-Infos into a List like this: List<UserControlDetails> myList; public

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.