|
发表于 2013-11-2 14:37:36
|
显示全部楼层
本帖最后由 nyfor 于 2013-11-2 14:49 编辑
如果你要使用 ImageEdit , 那么请这样:
不要使用 QueryPopup 事件,改而使用 ParseEditValue 事件
private void repositoryItemImageEdit1_ParseEditValue(object sender, DevExpress.XtraEditors.Controls.ConvertEditValueEventArgs e)
{
if (e.Value != null && e.Value is string && e.Value.ToString() != string.Empty)
{
String imgpath = Application.StartupPath + "\\img\\" + e.Value.ToString();
e.Value = Image.FromFile(imgpath);
e.Handled = true;
}
}
|
评分
-
查看全部评分
|