-1

How can I get video from default video application in iPhone/iPod ?

I am not finding any way to get access to videos stored in default video application in iPhone/iPod.

Please suggest me way to have access to those videos.

nimrod
  • 5,595
  • 29
  • 85
  • 149
S S
  • 193
  • 1
  • 1
  • 11
  • This forum is for programming problems/help, not Apple-related stuff. Your question is related to using your iPod (which you didn't even specify which model), which is nothing to do with programming. Your question is off-topic. If you want to post this on StackExchange, don't post this on StackOverflow, try [AskDifferent](http://apple.stackexchange.com/). –  Jan 08 '13 at 08:48
  • I want to play videos in my application from video folder – S S Jan 08 '13 at 08:50
  • Oh! Then why didn't you explain? Why programming language? Add tags accordingly. Is this XCode? –  Jan 08 '13 at 08:50
  • ok sorry, please tell me solution for that – S S Jan 08 '13 at 08:51
  • For what? Xcode? Why don't you edit your question? –  Jan 08 '13 at 08:51
  • 1
    'give me teh codez' type questions are frowned upon on Stackoverflow. – dandan78 Jan 08 '13 at 08:52
  • 1
    Yeah. [What have you tried](http://www.whathaveyoutried.com/)? –  Jan 08 '13 at 08:53
  • 2
    @Dumb Search please, be more careful calling Xcode, Delphi, Eclipce, Visual Studio, etc. a 'programming language' at this kind of questions :) – A-Live Jan 08 '13 at 08:54
  • I have tried this [link](http://stackoverflow.com/questions/3781620/can-you-play-video-from-the-ipod-library) – S S Jan 08 '13 at 09:08
  • 1
    @user Then edit your question to include the relevant code. But only the relevant code. And explain what kind of problem you are having. That is how Stackoverflow works. Read the [faq] and follow the rules if you want a decent answer. Failure to do so will result in downvotes and an eventual ban. – dandan78 Jan 08 '13 at 09:53
  • I have again edited my question, now is it okay to give answer ? – S S Jan 08 '13 at 10:06
  • @A-Live Yeah, I know, it's a compilar. My point was to ask witch coding language he was using, eg. C or Java or something. –  Jan 08 '13 at 17:44

1 Answers1

0

Finally i got the answer :)

MPMediaPropertyPredicate *predicate = [MPMediaPropertyPredicate predicateWithValue:[NSNumber numberWithInteger:MPMediaTypeMovie] forProperty:MPMediaItemPropertyMediaType];

MPMediaQuery *query = [[MPMediaQuery alloc] init];
[query addFilterPredicate:predicate];

NSArray *items = [query items];
NSURL *url = [[NSURL alloc]init];
for (MPMediaItem* item in items)
{
    NSString* title = [item valueForProperty:MPMediaItemPropertyTitle];

     url = [item valueForProperty:MPMediaItemPropertyAssetURL];
    NSLog(@"url %@",url);
}
S S
  • 193
  • 1
  • 1
  • 11