Exitjs获取DataView中图片文件名

1、前台
复制代码 代码如下:



2、后台
复制代码 代码如下:

protected void Page_Load(object sender, EventArgs e)
{
string path = Server.MapPath("images/thumbs");
string[] files = System.IO.Directory.GetFiles(path);
List data = new List(files.Length);
foreach (string fileName in files)
{
System.IO.FileInfo fi = new System.IO.FileInfo(fileName);
data.Add(new { name = fi.Name,
url = "images/thumbs/" + fi.Name,
size = fi.Length,
lastmod = fi.LastAccessTime });
}
this.Store1.DataSource = data;
this.Store1.DataBind();
}

你可能感兴趣的:(Exitjs获取DataView中图片文件名)