LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Closed Thread
  Search this Thread
Old 01-19-2012, 07:29 AM   #1
shweta_salve
LQ Newbie
 
Registered: Jan 2012
Posts: 2

Rep: Reputation: Disabled
How to Embed media file in monodevlop Application


hello!!!
im using ubunti 11.10 to create c# application wid the help of monodevelop
im trying to embed media file in my monodevelop app bt i cant achieve it.
i hav written a code to embed mplayer in monodevlop bt it open mplayer exe seperately .i want it to embed in monodevelop widget.so please go through my code:
-----code-----
using System;
using Gtk;
using System.Runtime.InteropServices;

public partial class MainWindow : Gtk.Window
{
private Gtk.Socket socket;
private int xid;

public MainWindow () : base(Gtk.WindowType.Toplevel)
{
Build ();
this.socket = new Socket();
this.socket.WidthRequest = 320;
this.socket.HeightRequest = 240;
this.socket.Visible = true;
this.socket.Realized += new EventHandler(OnVideoWidgetRealized);
this.fixed2.Put(socket, 0, 0);
}

protected virtual void OnVideoWidgetRealized (object sender, EventArgs args)
{
this.xid = (int)socket.Id;
}

protected void OnDeleteEvent (object sender, DeleteEventArgs a)
{
Application.Quit ();
a.RetVal = true;
this.socket = new Socket();
}

protected virtual void OnButton17Clicked (object sender, System.EventArgs e)
{
var paramString = string.Format("-wid {0} -vo x11 -really-quiet -msglevel all=-1 gooddog.wmv", xid);
System.Diagnostics.Process proc = new System.Diagnostics.Process();
proc.StartInfo.FileName = "/usr/bin/mplayer";
proc.StartInfo.Arguments = paramString;
proc.Start();
proc.WaitForExit();
}
}
 
Old 01-19-2012, 07:22 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,331
Blog Entries: 55

Rep: Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529
Please post your thread once and in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread should be closed because it is a duplicate of http://www.linuxquestions.org/questi...cation-924578/.
 
  


Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Embed media file in monodevlop Application shweta_salve Linux - General 0 01-19-2012 07:04 AM
[SOLVED] How can I embed JMF library in java application (Netbean)? hakeemtunde Programming 1 08-09-2011 12:38 PM
How to embed xterm in qt-3 application? maradnus Linux - Newbie 1 10-08-2009 03:45 PM
How can i embed firefox into kde-qt application? ispecial Linux - Software 1 07-06-2005 09:52 PM
embed a media player on the webpage felnlily Linux - Software 1 02-11-2005 11:27 AM


All times are GMT -5. The time now is 10:11 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration