C# 中如何获得屏幕宽度和高度
来源:互联网 发布:2016年中国出口数据 编辑:程序博客网 时间:2024/05/17 06:31
//1、在屏幕的右下角显示窗体
//这个区域不包括任务栏的
Rectangle ScreenArea = System.Windows.Forms.Screen.GetWorkingArea(this);
//这个区域包括任务栏,就是屏幕显示的物理范围
//这个区域包括任务栏,就是屏幕显示的物理范围
Rectangle ScreenArea = System.Windows.Forms.Screen.GetBounds(this);
int width1 = ScreenArea.Width; //屏幕宽度
int height1 = ScreenArea.Height; //屏幕高度
this.Location = new System.Drawing.Point(width1 - 窗体宽度, height1 - 窗体高度); //指定窗体显示在右下角
int height1 = ScreenArea.Height; //屏幕高度
this.Location = new System.Drawing.Point(width1 - 窗体宽度, height1 - 窗体高度); //指定窗体显示在右下角
//2、在母窗体的中间显示子窗体的位置计算
waitForm.Location = new Point((this.Location.X + (this.Width - waitForm.Width) / 2),
(this.Location.Y + (this.Height - waitForm.Height) / 2));
(this.Location.Y + (this.Height - waitForm.Height) / 2));
- C# 中如何获得屏幕宽度和高度
- C# 中如何获得屏幕宽度和高度
- C# 中如何获得屏幕宽度和高度
- C# 中如何获得屏幕宽度和高度
- C#如何获得屏幕宽度和高度
- C# 中如何获得屏幕宽度和高度【申明:来源于网络】
- 获得屏幕高度和宽度
- ionic开发中屏幕的宽度和高度的获得
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- android获得屏幕高度和宽度
- 获得手机的屏幕高度和宽度
- android获得屏幕高度和宽度
- 20130725 工作日志 jdk配置
- android开发 打开系统设置信息页面
- VisionMobile:2013年Q3移动开发者经济报告(三):第二章、生态系统经济:在逆境中竞争
- 斐波那契数列
- 判断块是否为匿名块
- C# 中如何获得屏幕宽度和高度
- c++ builder\delphi中如何改变操作数据库时的鼠标指针形状
- 亲身动手做网站SEO
- find the most comfortable road(hdu并查集+暴力)
- 网络编程笔记
- 无意中发现的WIN7的BUG
- Linux怎样修改系统时间
- C# 学习之装箱和拆箱
- freemarker高级用法1