using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms; namespace proj_92
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
} private void Form1_Load(object sender, EventArgs e)
{
checkedListBox1.Items.Add("中国"); checkedListBox1.Items.Add("美国");
checkedListBox1.Items.Add("俄罗斯"); checkedListBox1.Items.Add("英国");
checkedListBox1.Items.Add("法国"); checkedListBox1.CheckOnClick = true;
textBox1.Text = DateTime.Now.ToString("h:mm:ss");
timer1.Enabled = true;
timer1.Interval = ; hScrollBar1.Maximum = ; hScrollBar1.Minimum = ;
hScrollBar1.SmallChange = ; hScrollBar1.LargeChange = ;
vScrollBar1.Maximum = ; vScrollBar1.Minimum = ;
vScrollBar1.SmallChange = ; vScrollBar1.LargeChange = ;
hScrollBar1.Value = ; vScrollBar1.Value = ; dateTimePicker1.Format = DateTimePickerFormat.Long;
dateTimePicker1.ShowCheckBox = true;
dateTimePicker1.ShowUpDown = false;
textBox3.Text = ""; linkLabel1.LinkColor = Color.Blue;
linkLabel1.ActiveLinkColor = Color.Green; } private void button1_Click(object sender, EventArgs e)
{
foreach (object item in checkedListBox1 .CheckedItems )
{
listBox1.Items.Add(item);
}
} private void timer1_Tick(object sender, EventArgs e)
{
textBox1.Text = DateTime.Now.ToString("h:mm:ss"); } private void hScrollBar1_Scroll(object sender, ScrollEventArgs e)
{
textBox2.Text = hScrollBar1.Value.ToString("d");
vScrollBar1.Value = hScrollBar1.Value;
} private void vScrollBar1_Scroll(object sender, ScrollEventArgs e)
{
textBox2.Text = vScrollBar1.Value.ToString("d");
hScrollBar1.Value = vScrollBar1.Value;
} private void button2_Click(object sender, EventArgs e)
{
if (Convert .ToInt16 (textBox2 .Text )>= && Convert .ToInt16 (textBox2 .Text )<= )
{
hScrollBar1.Value = Convert.ToInt16(textBox2.Text);
vScrollBar1.Value = Convert.ToInt16(textBox2.Text);
}
} private void dateTimePicker1_ValueChanged(object sender, EventArgs e)
{
textBox3.Text = dateTimePicker1.Value.ToString("yyyy.MM.dd hh:mm:ss");
} private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
System.Diagnostics.Process.Start("http://blog.sina.com.cn/s/articlelist_2379298071_0_1.html");
}
}
}

带复选框的列表控件,定时器控件,滚动条控件,月历控件,日期时间控件,超链接控件

c# windows编程控件学习-2的更多相关文章

  1. c# windows编程控件学习-1

    using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; usin ...

  2. [转]Windows平台下Makefile学习笔记

    Windows平台下Makefile学习笔记(一) 作者:朱金灿 来源:http://blog.csdn.net/clever101 决心学习Makefile,一方面是为了解决编译开源代码时需要跨编译 ...

  3. DevExpress控件学习总结(转)

    DevExpress控件学习总结   1.Navigation & Layout 1.1 Bar Manager 如果想在窗体或用户控件(user control)上添加工具条(bars)或弹 ...

  4. Windows标准控件

    学习目的 学习创建, 使用Windows标准控件(按钮, 滚动条, 静态控件, 列表框, 编辑框, 组合框); 学习使用子窗口控件操作函数(EnableWindow, MoveWindow, SetW ...

  5. 如何:对 Windows 窗体控件进行线程安全调用

    http://msdn.microsoft.com/zh-cn/library/ms171728(VS.90).aspx http://msdn.microsoft.com/zh-cn/library ...

  6. C#可扩展编程之MEF学习笔记(五):MEF高级进阶

    好久没有写博客了,今天抽空继续写MEF系列的文章.有园友提出这种系列的文章要做个目录,看起来方便,所以就抽空做了一个,放到每篇文章的最后. 前面四篇讲了MEF的基础知识,学完了前四篇,MEF中比较常用 ...

  7. C#可扩展编程之MEF学习笔记(四):见证奇迹的时刻

    前面三篇讲了MEF的基础和基本到导入导出方法,下面就是见证MEF真正魅力所在的时刻.如果没有看过前面的文章,请到我的博客首页查看. 前面我们都是在一个项目中写了一个类来测试的,但实际开发中,我们往往要 ...

  8. C#可扩展编程之MEF学习笔记(三):导出类的方法和属性

    前面说完了导入和导出的几种方法,如果大家细心的话会注意到前面我们导出的都是类,那么方法和属性能不能导出呢???答案是肯定的,下面就来说下MEF是如何导出方法和属性的. 还是前面的代码,第二篇中已经提供 ...

  9. C#可扩展编程之MEF学习笔记(二):MEF的导出(Export)和导入(Import)

    上一篇学习完了MEF的基础知识,编写了一个简单的DEMO,接下来接着上篇的内容继续学习,如果没有看过上一篇的内容, 请阅读:http://www.cnblogs.com/yunfeifei/p/392 ...

随机推荐

  1. RecycleView可以策划的Item

    public abstract class SwipeMenuViewHolder { /* 从左侧滑出菜单 */ public static final int EDGE_LEFT = 1; /* ...

  2. python学习笔记六 面向对象相关下(基础篇)

    面向对象基本知识: 面向对象是一种编程方式,此编程方式的实现是基于对 类 和 对象 的使用 类 是一个模板,模板中包装了多个“函数”供使用(可以将多函数中公用的变量封装到对象中) 对象,根据模板创建的 ...

  3. Java开发中经典的小实例-(打印九九乘法表)

    public class Test16 {    public static void main(String[] args) {        // TODO Auto-generated meth ...

  4. Struts2之Action

    Struts2之Action MVC模式中需要有一个控制器来负责浏览器与服务器之间的通信,实现用户与服务器的交互.在Struts2框架中实现这一功能的是Action,它是整个框架最核心的部分.Acti ...

  5. 后勤数据抽取流程图 Logistic Data Extraction

    声明:原创作品,转载时请注明文章来自SAP师太技术博客( 博/客/园www.cnblogs.com):www.cnblogs.com/jiangzhengjun,并以超链接形式标明文章原始出处,否则将 ...

  6. 自建数据源(RSO2)、及数据源增强

    声明:原创作品,转载时请注明文章来自SAP师太技术博客( 博/客/园www.cnblogs.com):www.cnblogs.com/jiangzhengjun,并以超链接形式标明文章原始出处,否则将 ...

  7. Ubuntu 16.04 + Caffe

    主要参考: https://github.com/BVLC/caffe/wiki/Ubuntu-16.04-or-15.10-Installation-Guide http://caffe.berke ...

  8. Redis - 发布和订阅

    一.概述 1). 发布和订阅是一种消息通信模式. 2). 优点:使消息订阅者和消息发布者耦合度降低,类似设计模式中的观察者模式. 二.发布和订阅 订阅命令: // 订阅一个或多个频道 // 返回值:v ...

  9. SQL&&LINQ:左(外)连接,右(外)连接,内连接,完全连接,交叉连接,多对多连接

    SQL: 外连接和内连接: 左连接或左外连接:包含左边的表的所有行,如果右边表中的某行没有匹配,该行内容为空(NULL) --outer jion:left join or left outer jo ...

  10. 深入浅出设计模式——装饰模式(Decorator Pattern)

    模式动机 一般有两种方式可以实现给一个类或对象增加行为: 继承机制,使用继承机制是给现有类添加功能的一种有效途径,通过继承一个现有类可以使得子类在拥有自身方法的同时还拥有父类的方法.但是这种方法是静 ...