• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

App Inventor Download text file with TextView using Html.fromHtml

When I use this code it displays the text in the file Myfilecontainingtext.abc
How can I make it instead download the file to the downloads directory?

Java:
        String html1 = "<a href='http://www.mywebsite.com/Myfilecontainingtext.abc'>Download Myfilecontainingtext.abc to Downloads directory</a>";
        TextView textView1 = (TextView) findViewById(R.id.textView1);
        textView3.setText(Html.fromHtml(html1));
        textView1.setMovementMethod(LinkMovementMethod.getInstance());
 
Back
Top Bottom