public partial class Flash_Quran : Form
{
[DllImport("USER32.DLL")]
static extern IntPtr SetParent(IntPtr hWndChild, IntPtr hWndNewParent);
[DllImport("USER32.dll")]
private static extern bool MoveWindow(IntPtr hwnd, int x, int y, int cx, int cy, bool repaint);
public Flash_Quran()
{
InitializeComponent();
}
private void Flash_Quran_Load(object sender, EventArgs e)
{
Process process = Process.Start("QuranFull.exe");
process.WaitForInputIdle();
SetParent(process.MainWindowHandle, this.panel1.Handle);
MoveWindow(process.MainWindowHandle, 0, 0, this.Width - 90, this.Height, true);
}
}
this code use