2011年4月20日
摘要: 当新建一个wpf应用程序,会自动生成一个App.xaml和MainWindow.xaml文件其中App.xam用来设置Application,应用程序的起始文件和资源及应用程序的一些属性和事件的设置,app.xaml.cs是处理应用程序的相关资源和事件MainWindow.xaml是相应的窗体文件app.xaml及app.xaml.cs主要通过操作application对象来控制应用程序application对象包含的事件 名称 说明 Activated 当应用程序成为前台应用程序时发生。 Deactivated 当应用程序停止作为前台应用程序时发生。 DispatcherUnhandledE 阅读全文
posted @ 2011-04-20 22:31 dezi 阅读(2916) 评论(0) 推荐(0) 编辑
摘要: 编写winform(C#.net)程序中使用下拉框控件时,无法指定选择项的解决办法首先定义类 public class ItemListHelp { public string text { get; set; } public string vlaue { get; set; } }然后绑定ComboBox控件 DataTable ta=GetAllFieldByLetterType(); if(ta!=null) { drop_field.Items.Clear(); foreach(DataRow row in ta.Rows) { ItemListHelp item1=new Item 阅读全文
posted @ 2011-04-20 18:28 dezi 阅读(1078) 评论(0) 推荐(0) 编辑