searching for a folder
Hi
I am trying to search for a particular folder through BOX java sdk search. BUt i am getting all the folders that match atleast substring of the given folder name. i would like to know if there is any adavanced search to get the rightt folder as is rather than getting all the folders which contain substring of the given folder name
Thanks
-
You can run an exact match search by putting your query in quotes. Please keep in mind that you have to escape the quotes with backslashes.
Here is an example using our Java SDK.
BoxFolder rootFolder = BoxFolder.getRootFolder(api); Iterable<BoxItem.Info> results = rootFolder.search("\" text to find \""); for (BoxItem.Info result : results) { // Do something with the search result. }
Please sign in to leave a comment.
Comments
1 comment