Reading documents list
Hi
How can the list of documents retrieved from a specific library via code in for the purpose of displaying the documents in a custom widget?
Thanks
Regards
Hi John,
You can use the fluent API.
App.WorkWith().Documents().Where(d => d.Status == Telerik.Sitefinity.GenericContent.Model.ContentLifecycleStatus.Live).Get().ToList();
Hi
Many thanks.
This one is bringing all the documents from all libraries. Any way to restrict the returned documents from "staff documents" library only?
Also is there a way to read user friendly document filename from library or the only way is to extract file name from Media Url field?
Thanks
Regards
Hi John,
You can add an condition in the Where statement
&& d =>d.Title == "test"
You can use all Document properties inside the Where query.
Kind regards,
Ivan Dimitrov
the Telerik team