How i save something on SIM

Put your problem here if it does not fit any of the other categories.

How i save something on SIM

Postby Quelle » Wed Sep 08, 2010 5:25 pm

Hey Guys,

how it`s possible to save something on a SIM-card?

In internet i find just

you can see
packages/apps/Phone/src/com/android/phone/ANDList.java


But i don`t know where i can find this JAVA-File.

Regards Quelle
Quelle
Developer
Developer
 
Posts: 34
Joined: Thu Mar 11, 2010 10:53 am

Top

Re: How i save something on SIM

Postby Quelle » Thu Sep 09, 2010 5:26 pm

Hi Guys,

i want to share my experience with you.

Code: Select all
   public boolean insertEntryOnSim(ContentResolver ctR){
      Log.i(TAG, "insertEntryOnSim");
      Uri simUri = Uri.parse("content://icc/adn");
//      Uri simUri = Uri.parse("content://sim/adn");
      
      ContentValues values = new ContentValues();
      values.put("tag", "hans wurst");
      values.put("number", "010906765");

      ContentResolver resolver = ctR;
      Uri row = resolver.insert(simUri, values);
      
      if (row == null) {
         return false;
      }


      values.clear();
      
         return true;
   }

Quelle
Developer
Developer
 
Posts: 34
Joined: Thu Mar 11, 2010 10:53 am

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: Google [Bot], Yahoo [Bot] and 23 guests