O'Reilly logo

Xamarin Studio for Android Programming: A C# Cookbook by Mathieu Nayrolles

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Simple file reading/writing

One of the oldest and simplest ways to persist data in every system and on every language is to create a file, write our data into it, and eventually read that data at a determined time. Despite the perceived simplicity of reading and writing files, there are some obstacles to overcome in Android for security reasons. Indeed, applications are not allowed to write to/read from every part of the phone. Moreover, the file could be formatted in different ways. In this recipe, we will focus on how to read and write simple files.

Getting ready

For this recipe we will continue to use the project created in the previous recipe.

How to do it...

In the introduction of this recipe we state that, for security reasons, applications ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required