daixinet

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

随笔分类 -  .net之WPF

WPF页面开发点滴
摘要:1、效果图:2、XAML ... 阅读全文
posted @ 2015-06-26 15:38 daixinet.com 阅读(674) 评论(0) 推荐(0)

摘要:m_Element.Fill = SystemColors.WindowBrush;BorderBrush="{x:Static SystemColors.WindowBrush}" 阅读全文
posted @ 2013-08-09 11:25 daixinet.com 阅读(193) 评论(0) 推荐(0)

摘要:做了一个自定义控件和一个自定义Grid,里面的元素可以随着绑定属性变化:效果图(一定滑块):关键代码:1、自定义属性代码: public class MyGrid : Grid { public static readonly DependencyProperty ColumnCountProperty = DependencyProperty.Register("ColumnCount", typeof(int), typeof(MyGrid), new FrameworkPropertyMetadata((int)1,FrameworkPr... 阅读全文
posted @ 2013-08-04 19:21 daixinet.com 阅读(2517) 评论(0) 推荐(0)

摘要:效果图:下载:Code参考:http://www.codeproject.com/Articles/33001/WPF-A-Simple-Color-Picker-With-Previewhttp://www.codeproject.com/Articles/229442/WPF-Color-Pic... 阅读全文
posted @ 2013-07-31 12:08 daixinet.com 阅读(1817) 评论(0) 推荐(1)

摘要:Intersoft ClientUI 阅读全文
posted @ 2013-05-08 15:19 daixinet.com 阅读(238) 评论(0) 推荐(0)

摘要:调用方法: ReturnObject loadReturnObject = WaitingWindow.Show("正在加载", aBO, "GetA", new Object[] { "", "", "", "", m_IteratorValues, false }) as ReturnObject;下载:Code 阅读全文
posted @ 2013-04-22 09:50 daixinet.com 阅读(1104) 评论(1) 推荐(0)

摘要: 阅读全文
posted @ 2013-03-27 22:26 daixinet.com 阅读(320) 评论(0) 推荐(0)

摘要:iPad塔防的防守兵的效果很炫,2个小时用WPF模拟了一个。效果图:关键代码: <Grid> <Grid.Background> <ImageBrush ImageSource="Koala.jpg"/> </Grid.Background> <Button Content="Button1" HorizontalAlignment="Left" Margin="187,107,0,0" VerticalAlignment="Top" Wid 阅读全文
posted @ 2013-03-26 01:18 daixinet.com 阅读(1268) 评论(0) 推荐(0)

摘要:参考:http://code.msdn.microsoft.com/WPF-Autocomplete-Textbox-df2f1791#content问题:1、获得焦点时,不自动搜索2、按向下的箭头时,不自动到下拉项3、输入中文,挡住输入框针对这几个问题,做了控件的修改,1、获得焦点时,添加GotF... 阅读全文
posted @ 2012-10-25 14:15 daixinet.com 阅读(1609) 评论(1) 推荐(1)

摘要:最近看一个帖子,做不规则按钮,写的非常好。超链接:http://blog.csdn.net/cmis7645/article/details/7592372#comments效果图:代码:View Code 代码不是很难理解,关键是P... 阅读全文
posted @ 2012-09-12 11:05 daixinet.com 阅读(11560) 评论(6) 推荐(4)

摘要:效果图:用于提示用户的输入代码:Code 阅读全文
posted @ 2012-09-11 11:21 daixinet.com 阅读(2144) 评论(0) 推荐(0)

摘要:把图片生成资源,怎么在后台访问困扰了我几天,在网上也查了很多例子,各种说法都有如:m_Image.Source = new BitmapImage(new Uri(@"Resources/Images/more.png", UriKind.Relative));但是在实际进行过程中,访问不到。经过测试,很简单就能访问到了:Code:m_Image.Source = new BitmapImage(new Uri("Images/more.png", UriKind.Relative));上两级文件夹:m_Image.Source = new Bitmap 阅读全文
posted @ 2012-09-06 09:35 daixinet.com 阅读(3095) 评论(0) 推荐(0)

摘要:图片:源码:Code 阅读全文
posted @ 2012-09-03 09:36 daixinet.com 阅读(570) 评论(0) 推荐(0)

摘要:WPF调用WinForm中的 OpenFileDialog 和 FolderBrowserDialog 来实现响应的功能 OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Title = "选择文件"; openFileDialog.Filter = "zip文件|*.zip|rar文件|*.rar|所有文件|*.*"; openFileDialog.FileName = string.Empty; openFileDi... 阅读全文
posted @ 2012-08-29 15:57 daixinet.com 阅读(16223) 评论(0) 推荐(1)

摘要:0、更改模板效果:代码: ... 阅读全文
posted @ 2012-08-22 15:40 daixinet.com 阅读(30872) 评论(0) 推荐(3)

摘要:http://code.msdn.microsoft.com/windowsdesktop/Dynamic-Image-Button-in-WPF-caec28b7#content 阅读全文
posted @ 2012-08-21 14:39 daixinet.com 阅读(1250) 评论(0) 推荐(0)

摘要:在WPF中设计登录窗口关闭时打开主窗口,自动生成的App.xaml不能满足要求,1、把App.xaml的属性窗口中的生成操作设定为 无2、添加Program类 static class Program { /// /// The main entry point for the application. /// [STAThread] static void Main() { LoginWindow loginForm = new LoginWindow(); ... 阅读全文
posted @ 2012-08-16 14:26 daixinet.com 阅读(14439) 评论(7) 推荐(1)

摘要:WPF和Silverlight环境下KeyDown和KeyUp的本身不同,其中KeyDown不响应一些功能键,而KeyUp响应。 阅读全文
posted @ 2012-08-16 10:45 daixinet.com 阅读(2185) 评论(0) 推荐(0)

摘要:今天做WPF项目,遇到添加引用后,在代码中找不到引用,原来项目的目标框架为.NET Framework 4 Client Profile,把框架改为.NET Framework 4,编译通过 阅读全文
posted @ 2012-08-15 11:17 daixinet.com 阅读(251) 评论(0) 推荐(0)

摘要:枚举m_Theme.HorizontalAlignment = (HorizontalAlignment)Enum.Parse(typeof(HorizontalAlignment), m_HorizontalAlignment);结构m_Theme.FontWeight = (FontWeight)System.ComponentModel.TypeDescriptor.GetConverter(typeof(FontWeight)).ConvertFromString(m_FontWeightName); 阅读全文
posted @ 2012-07-31 15:39 daixinet.com 阅读(1354) 评论(0) 推荐(0)