我用下面方法启动的一个具有窗口的应用程序Apps:
System.Diagnostics.Process Apps;
Apps.Start();
我怎么用代码设置Apps在屏幕上显示的位置呢?我还想设定Apps窗口的大小(Apps运行的窗体是可用鼠标移动、调节大小的),有什么办法吗?
System.Diagnostics.Process Apps;
Apps.Start();
我怎么用代码设置Apps在屏幕上显示的位置呢?我还想设定Apps窗口的大小(Apps运行的窗体是可用鼠标移动、调节大小的),有什么办法吗?
解决方案 »
- [!急]服务器端怎么判断网页是通过链接打开而不是刷新页面
- windows 密码与sql server 2005的密码问题???
- API 高手请进 急!
- 关于textbox的刷新
- 请问,c#怎么调用c++写的基于com的dll?
- 简单的问题:如何将一个窗体设为另一个窗体的子窗体
- 请问如何将datagridview的内容包括列标题一起复制到剪贴板?
- 紧急求救!请问在C#中怎样获得文件的下列信息?文件大小,文件图标,双击时怎样调用相应的应用程序打开它?
- 怎樣改變MDI PARENT FORM的backcolor等
- 请问Typed DataSet怎么定义一个BLOB类型的字段?
- .net访问AutoCAD(新手请教)
- GridView中无法删除和编辑数据
[DllImport("user32.dll", SetLastError = true)]
private static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
[DllImport("user32.dll", SetLastError = true)]
private static extern long SetWindowPos(IntPtr hwnd, long hWndInsertAfter, long x, long y, long cx, long cy, long wFlags);
[DllImport("user32.dll", SetLastError = true)]
private static extern bool MoveWindow(IntPtr hwnd, int x, int y, int cx, int cy, bool repaint);
直接使用
this.StartPosition = FormStartPosition.Manual;
this.Location = new Point(
Screen.PrimaryScreen.WorkingArea.Width - this.Width,
Screen.PrimaryScreen.WorkingArea.Height - this.Height );否则
ProcessStartInfo info = new ProcessStartInfo( "iexplorer.exe", "这里的参数具体依赖EXE本身是否支持!" );