Finding/listing remote files
in
Programming Questions
•
1 year ago
Hi
I've written a bit of code that manipulates an image and, before I post it on openprocessing, I thought that it would be nice to provide it with a larger pool of images to play with than I can reasonably copy there. I would like it to look at a directory of images on a different website and choose one of those to manipulate.
The first does this:
String path = sketchPath;
String[] filenames = commandToListFileNames(path);
and I can change path to an absolute local path and get the right results.
String[] filenames = commandToListFileNames(path);
and I can change path to an absolute local path and get the right results.
The second does this:
java
.
io
.
File folder
=
new java
.
io
.
File
(dataPath
(
""
)
)
;
and if I have files matching the search criteria in the dataPath, I get results. I can't successfully change this to another path, relative or absolute. I've looked at the help for java.io.File and don't understand the syntax required.
and if I have files matching the search criteria in the dataPath, I get results. I can't successfully change this to another path, relative or absolute. I've looked at the help for java.io.File and don't understand the syntax required.
I can't, with either of these, provide an
http:// address. Is there a way of doing this?
Thanks
1