Skip to content

Instantly share code, notes, and snippets.

@kw0006667
Created October 30, 2012 09:09
Show Gist options
  • Save kw0006667/3979158 to your computer and use it in GitHub Desktop.
Save kw0006667/3979158 to your computer and use it in GitHub Desktop.
修改 Data 屬性名稱
namespace DataSource
{
/// <summary>
/// 可以在本身使用或巡覽至框架內的空白頁面。
/// </summary>
public sealed partial class MainPage : Page
{
private List<Data> myDatas;
public MainPage()
{
this.InitializeComponent();
this.myDatas = new List<Data>() { new Data("Tim", "NTUE-Game", "Assets/Icon.png"), new Data("Huadi", "Toy", "Assets/Icon.png") };
this.MyListViewitems.ItemsSource = this.myDatas;
}
}
public class Data
{
public Data(string name, string company, string imgPath)
{
this.Name = name;
this.Company = company;
this.ImagePath = imgPath;
}
public string Name { get; set; }
public string Company { get; set; }
public string ImagePath { get; set; }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment