How to view pdf in android browser?
friends,
开发者_运维百科any one guide me how can i view pdf file in android browser?
or any other useful way?
any help would be appreciated.
Try this:
Intent intent = new Intent(Intent.ACTION_VIEW);
File file = new File("filename");
intent.setDataAndType(Uri.fromFile(file), "application/pdf");
startActivity(intent);
精彩评论