public bool BringTopForMs(int ms = 1000) { bool rt = false; DateTime now = DateTime.Now; while (!rt && now.xElapse().TotalMilliseconds < (double)ms) { if (WinApi.BringTop(this.RootHwnd)) { rt = true; } else { Thread.Sleep(50); } } return(rt); }
public void BringTop() { WinApi.BringTop(Hwnd.Handle); }