Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8487325
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T21:12:14+00:00 2026-06-10T21:12:14+00:00

I am trying to play a video in my ViewController. Mediaplayer.framework and all the

  • 0

I am trying to play a video in my ViewController. Mediaplayer.framework and all the Headers are in my Frameworks folder, including the MediaPlayer.h file. But when I put

#import "TutorialViewController.h"
#import <MediaPlayer/MediaPlayer.h>

@interface TutorialViewController ()

@end

@implementation TutorialViewController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
[super viewDidLoad];

    MPMoviePlayerController *player =
    [[MPMoviePlayerController alloc]
     initWithContentURL:[NSURL fileURLWithPath:url]];


    [[NSNotificationCenter defaultCenter]
     addObserver:self
     selector:@selector(movieFinishedCallback:)
     name:MPMoviePlayerPlaybackDidFinishNotification
     object:player];

    //---play movie---
    [player play];
    [super viewDidLoad];
}

- (void) movieFinishedCallback:(NSNotification*) aNotification {
    MPMoviePlayerController *player = [aNotification object];
    [[NSNotificationCenter defaultCenter]
     removeObserver:self
     name:MPMoviePlayerPlaybackDidFinishNotification
     object:player];


// Do any additional setup after loading the view.
}


- (void)viewDidUnload
{
[super viewDidUnload];
    // Release any retained subviews of the main view.
}

- (BOOL)shouldAutorotateToInterfaceOrientation:        (UIInterfaceOrientation)interfaceOrientation
{
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

@end

in my .m file, I get an error stating ‘MediaPlayer/MediaPlayer.h’ file not found.
What does this mean and how can I fix this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T21:12:16+00:00Added an answer on June 10, 2026 at 9:12 pm

    Removing the framework from the project and re-adding it should solve this problem. What I would recommend you do is open your project’s directory and make sure that when you adding the framework to your project you only referenced the framework and didn’t copy it. If the framework exists within your project folder then delete it, otherwise just remove it’s reference from your project.

    Then navigate to:

    Project Navigator>>Your apps target>>Summary Tab(scrolled to bottom)

    Click the “+” under “Linked Frameworks” and from here you can re-add the reference to the framework to your project.

    enter image description here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to play a video file using JMF but it gives me
Video in res->raw folder.I want to play video directly in mediaplayer.I trying to search
I am trying to play the Video file on IE8 using quick time but
I'm trying to play video from youtube using this code but I get this
I'm trying to play a youtube video on my Android app, but I can't
I am trying to play .avi file in video lightbox by over riding it's
i'm trying to play a video with MediaPlayer and MediaController. The video starts and
I'm trying to play a video using vlcj inside a JPanel but it doesn't
I'm trying to load an intent to play a video file on my phone's
I am using VideoView trying to play video. But when I use this code

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.