I want to fetch all audio files and also video files from device into the app. so that i can listed their names into the different UITableViews. Is there any way in ios, so
Have a look at this,specially on the section "Getting Media Items Programmatically".
If the media item picker doesn’t provide the control you want, you can use the database access classes from this API. These classes are designed to let you create arbitrarily complex queries. You could, for example, retrieve all the songs in a particular genre whose titles include a particular word or phrase.
Using programmatic access is a two step process:
Configure a query. Ask the query to retrieve its matching media items. A media query is a description of what to retrieve from the device iPod library and how those retrieved items should be arranged. It has two properties to configure:
The filter is the description of what to retrieve. The filter is optional; a filterless query matches the entire iPod library. The grouping type is an optional key that specifies the arrangement to use for retrieved collections of media items. Zooming in a bit more, the filter can be as simple or complex as your application demands. It consists of one or more instances of a media property predicate. A media property predicate is a statement of a logical condition to test each media item against. The items that satisfy the filter are retrieved from the iPod library when you invoke the query.
The optional grouping type specifies the arrangement and sorting of collections as well as the sorting of media items within each collection. For example, using an “album” grouping type results in returned media items grouped by album, with each album’s songs sorted in track order.
For more help,check these links :
Retrieve list of songs ordered by last play time in iOS
how to get list of all the songs in ipodLibrary in an Array
Iphone: How to show list of songs from library inside application
http://mobisoftinfotech.com/integrate-music-player-in-iphone/
Heres your Answer... Access device music files from iPhone app programmatically
You could've got it yourself if you googled it..