How to initialize ActiveX Object In c#.net
my code:
private AxWMPLib.AxWindowsMediaPlayer axWindowsMediaPlayer1;
this.axWindowsMediaPlayer1
= new AxWMPLib.AxWindowsMediaPlayer();
((System.ComponentModel.ISupportInitialize)(this.axWindowsMediaPlayer1)).BeginInit();
this.SuspendLayout();
//
//
axWindowsMediaPlayer1
//
axWindowsMediaPlayer1.Dock = DockStyle.Fill;
this.axWindowsMediaPlayer1.Enabled = true;
this.axWindowsMediaPlayer1.Location = new System.Drawing.Point(112, 88);
this.axWindowsMediaPlayer1.Name = "axWindowsMediaPlayer1";
this.axWindowsMediaPlayer1.OcxState =
((System.Windows.Forms.AxHost.State)(Resources.ResourceManager.GetObject("axWindowsMediaPlayer1.OcxState")));
//this.axWindowsMediaPlayer1.Size = new System.Drawing.Size(384, 248);
this.axWindowsMediaPlayer1.TabIndex = 0;
axWindowsMediaPlayer1.URL = url; //here url contain file location
axWindowsMediaPlayer1.Ctlcontrols.play();
when i
run this program it show me error that getobject method is not a part
of resources.resourcemanager namespace