|
Any raw assets you want to be deployed with your application can be placed in
this directory (and child directories) and given a Build Action of "AndroidAsset".
These files will be deployed with you package and will be accessible using Android's
AssetManager, like this:
public class ReadAsset : Activity
{
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
InputStream input = Assets.Open ("my_asset.txt");
}
}
Additionally, some Android functions will automatically load asset files:
Typeface tf = Typeface.CreateFromAsset (Context.Assets, "fonts/samplefont.ttf");
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
Sandip is a "Software Architect, CEO, Founder at ClarityCX Solutions & Services Private Limited"
He has 24 years of rich experience working in software development in the areas of market research, web, mobile and e-commerce.
Sandip has wide ranging experience in C#, VB.NET, ASP.Net, JQuery, JSON, LINQ, WCF, WPF, NodeJs, MongoDB, AngularJS, Express, Silverlight, SOA, Android, IPhone, IPad and Windows Mobile applications.
Specialized in Hybrid and Native Apps in iOS, Android, Windows Phone, Blackberry, Symbian, Tizen, WebOS.
Sandip can be reached at sandip.net@gmail.com
Tweet: @sandipnascar
FB: https:sandipnascar
View My Page