Reading from URL - Java, C#, Android, Visual Studio -
is possible read url directed text file. e.g. https://dl.dropboxusercontent.com/u/53441658/read.txt
instead of giving file path located on computer, want give path text file, via url. this;
streamwriter sw = new streamwriter("https://dl.dropboxusercontent.com/u/53441658/read.txt", true);
in java (android)
url url = new url("ftp://mirror.csclub.uwaterloo.ca/index.html"); urlconnection urlconnection = url.openconnection(); inputstream in = new bufferedinputstream(urlconnection.getinputstream()); try { readstream(in); { in.close(); } }
p.s. must in separate thread async task. read more on android official documentation.
in dot.net c#
using(webclient client = new webclient()) { string s = client.downloadstring(url); }
Comments
Post a Comment