Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# xamarin forms use AssetManager to get text file

// c# Xamarin Forms for Andriod
string text = string.Empty;
string filename = "TestList.txt";

AssetManager assets = Android.App.Application.Context.Assets;
using (StreamReader reader = new StreamReader(assets.Open(filename)))
{
    text = reader.ReadToEnd();
}

 
PREVIOUS NEXT
Tagged: #xamarin #forms #AssetManager #text #file
ADD COMMENT
Topic
Name
5+1 =