If you want to play 2 videos at the same time you need to enter 3 parts of code:
Part 1:
using System.Runtime.InteropServices;
Part 2:
under:
public Form1()
{
InitializeComponent();
}
enter code:
[DllImport("winmm.dll")]
private static extern long mciSendString(
string command,
StringBuilder returnValue,
int returnLength,
IntPtr winHandle);
Part 3:
string filename1 = "";
string filename2 = "";
mciSendString("close mf1", null, 0, IntPtr.Zero);
mciSendString("close mf2", null, 0, IntPtr.Zero);
mciSendString("open \"" + filename1 + "\" type mpegvideo alias mf1 style child parent " + pictureBox1.Handle.ToString(), null, 0, IntPtr.Zero);
mciSendString("open \"" + filename2 + "\" type mpegvideo alias mf2 style child parent " + pictureBox2.Handle.ToString(), null, 0, IntPtr.Zero);
mciSendString("put mf1 window at 0 0 " + pictureBox1.Width.ToString() + " " + pictureBox2.Height.ToString(), null, 0, IntPtr.Zero);
mciSendString("put mf2 window at 0 0 " + pictureBox2.Width.ToString() + " " + pictureBox2.Height.ToString(), null, 0, IntPtr.Zero);
mciSendString("play mf1", null, 0, IntPtr.Zero);
mciSendString("play mf2", null, 0, IntPtr.Zero);
this worked for me;if you want to know more about this code search for MCI(Media Control Interface)