如何用DevExpress创建简单的Windows 8磁贴效果
作者:mayz 来源:本站原创 浏览:Loading...次 发布时间:2013-08-23 评论:3条
DevExpress WPF 和 Silverlight中有一个功能很强大的Tile Layout Control,可以创建Windows 8磁贴效果,下面将代码分享给大家:
using System;
using System.Collections.Generic;
using System.Windows;
using System.Windows.Media;
using System.Windows.Media.Imaging;
namespace WpfApplication2 {
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window {
public MainWindow() {
InitializeComponent();
}
public List<Agent> Agents { get { return WpfApplication2.Agents.DataSource; } }
}
public class Agent {
public string AgentName { get; set; }
public string Phone { get; set; }
public string Photo { get; set; }
public ImageSource PhotoSource {
get {
return string.IsNullOrEmpty(Photo) ? null : new BitmapImage(new Uri(Photo, UriKind.Relative));
}
}
}
public static class Agents {
public static readonly List<Agent> DataSource =
new List<Agent> {
new Agent { AgentName = "Anthony Peterson", Phone = "(555) 444-0782", Photo = "Images/1.jpg" },
new Agent { AgentName = "Rachel Scott", Phone = "(555) 249-1614", Photo = "Images/2.jpg" },
new Agent { AgentName = "Albert Walker", Phone = "(555) 232-2303", Photo = "Images/3.jpg" }
};
}
}
最终效果:
下载DXperience WPF/Silverlight制作磁贴效果
本站文章除注明转载外,均为本站原创或翻译
欢迎任何形式的转载,但请务必注明出处,尊重他人劳动成果
转载请注明:文章转载自:DevExpress控件中文网 [http://www.devexpresscn.com/]
本文地址:http://www.devexpresscn.com/Resources/CodeExamples-388.html
欢迎任何形式的转载,但请务必注明出处,尊重他人劳动成果
转载请注明:文章转载自:DevExpress控件中文网 [http://www.devexpresscn.com/]
本文地址:http://www.devexpresscn.com/Resources/CodeExamples-388.html
关键字: Windows 8 磁贴 Devexpress
评论列表
请谈谈你的看法 请使用IE或者Firefox浏览器,暂不支持Chrome!

慧都控件网为DevExpress界面控件的中国地区唯一正式授权经销商,正版控件销售公司,授权代理商,经销商及合作伙伴。
电话:400-700-1020
023-66090381
邮箱:sales@evget.com
相关资源
- 完美支持Windows®8
- 本地化(汉化).NET Windows Forms控件
- NavBar如何实现二级折叠效果
- 将ChartControl添加到Windows窗体中
- XtraCharts示例一:向Windows窗体应用程序中添加图表
- Windows8 UI应用程序
- DXTREME的神秘面纱
- DXTREME预览之Windows 8体验
- DevExpress Windows 8控件效果展示
- DevExpress Windows 8控件介绍及预览: Application Layout
- DevExpress Windows 8 XAML在线演示:Finance Tracker
- DevExtreme之DXSK8在线演示:Web应用程序
- DevExtreme在线演示:平板电脑
- DevExtreme之DXSK8在线演示:Phone
- DevExtreme之DXSK8在线演示:Windows8
- Windows 8 XAML常用示例一:创建表单布局
- Windows 8 XAML常用示例二:从数据源中植入幻灯片视图
- DXperience 12.2.8发布[附下载]
- XtraReports系列教程一:创建Windows Forms报表应用程序




