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

  • Home
  • SEARCH
  • 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 5999053
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T00:29:50+00:00 2026-05-23T00:29:50+00:00

I have added the Windows Media Player com control into my toolbox and then

  • 0

I have added the Windows Media Player com control into my toolbox and then used the control successfully on a Form in Debug mode.

However, when I try running the application in Release mode it errors with…

Could not load file or assembly
‘Interop.WMPLib, … or one of its
dependecies. An attempt was made to
load a program with an incorrect
format.

Through some tracing I’ve established that the error occurs not when creating the control but on the EndInit method.

Public Sub New

    InitializeComponent() 

    wmp = New AxWMPLib.AxWindowsMediaPlayer()
    wmp.BeginInit()
    wmp.Enabled = True
    wmp.Name = "wmp"
    wmp.OcxState = CType(resources.GetObject("wmp.OcxState"), AxHost.State)
    Me.Controls.Add(wmp)
    Me.Controls.SetChildIndex(wmp, 0)
    wmp.Dock = System.Windows.Forms.DockStyle.Fill
    wmp.EndInit()   ' <<< errors here !

End Sub

What am I missing?

  • 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-05-23T00:29:51+00:00Added an answer on May 23, 2026 at 12:29 am

    You changed the Platform target setting in the Debug configuration. Possibly weeks ago, maybe even in a previous version of Visual Studio. But didn’t change it in the Release configuration. It is one of the settings that is configuration specific.

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

Sidebar

Related Questions

I have written a control in C# that derives from System.Windows.Forms.Control. I have added
I have added some code which compiles cleanly and have just received this Windows
Consider System.Windows.Forms.StatusStrip . I have added a StatusStrip to my Windows Forms application, but
I have been made a windows service.in which i have been added project installer.in
I have Eclipse 3.4.2 installed on Windows with subclipse. Another developer added an SVN
I have started prgramming a windows service. I have added a notify icon from
I have a Windows Forms application (C#) containing a ListBox into which I have
I am developing windows mobile application. I have added the SQLite database file in
I have added following lines into php.ini [XDebug] zend_extension = C:\PROGRA~1\PHP5\ext\php_xdebug-2.1.0-5.3-vc9.dll xdebug.remote_enable=on xdebug.remote_handler=dbgp xdebug.remote_host=localhost
I have a Listview control lstStudents and i have added checkboxes inside the List

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.