[原] XAF How to Edit multiple objects in a ListViewAndDetailView
2014年好久没有更新Blog了,工作调换了,很少用XAF,但还是很关注XAF的发展和学习,对中国的中小企业数据管理软件开发真的太实用了!!
功能比较简单,但很实用,直接上图和代码!
ListView處於ListViewAndDetailView編輯模式
using System; using System.Linq; using System.Text; using DevExpress.ExpressApp; using DevExpress.Data.Filtering; using System.Collections.Generic; using DevExpress.Persistent.Base; using DevExpress.ExpressApp.Utils; using DevExpress.ExpressApp.Layout; using DevExpress.ExpressApp.Actions; using DevExpress.ExpressApp.Editors; using DevExpress.ExpressApp.Templates; using DevExpress.Persistent.Validation; using DevExpress.ExpressApp.SystemModule; using DevExpress.ExpressApp.Model.NodeGenerators; using DevExpress.Xpo; using DevExpress.XtraEditors; using DevExpress.ExpressApp.Win.Templates;namespace SimpleProjectManager.Module.Controllers {// For more typical usage scenarios, be sure to check out http://documentation.devexpress.com/#Xaf/clsDevExpressExpressAppViewControllertopic.public partial class EditerPlusieursLignesListViewController : ViewController<ListView>{public EditerPlusieursLignesListViewController(){InitializeComponent();RegisterActions(components);// Target required Views (via the TargetXXX properties) and create their Actions. }protected override void OnActivated(){base.OnActivated();if (View == null)return;if(((ListView)View).EditView == null)return;if( ((ListView)View).EditView.Items==null)return;foreach (ViewItem item in ((ListView)View).EditView.Items){item.ControlCreated += item_ControlCreated;}}void item_ControlCreated(object sender, EventArgs e){ViewItem item = (ViewItem)sender;if (item.Control.GetType() == typeof(NestedFrameTemplate)) return;((BaseEdit)item.Control).EditValueChanged += (sender2, e2) =>{if (View != null && View.SelectedObjects.Count > 1){foreach (XPBaseObject xpo in View.SelectedObjects){xpo.SetMemberValue(item.Id, ((BaseEdit)sender2).EditValue);}}};} } }
转载于:https://www.cnblogs.com/Tonyyang/p/4082914.html
[原] XAF How to Edit multiple objects in a ListViewAndDetailView相关推荐
- [原] XAF 添加日期筛选下拉选择
1.ListView 添加日期筛选下拉选择,选择指定,可指定日期范围 2.Code using DevExpress.Data.Filtering; using DevExpress.ExpressA ...
- [原] XAF How to implement a custom attribute to customize the Application Model
http://www.devexpress.com/Support/Center/Example/Details/E1679 转载于:https://www.cnblogs.com/Tonyyang/ ...
- Co-Fusion: Real-time Segmentation, Tracking and Fusion of Multiple Objects
这篇文章其实就是几篇文章凑在了一起. fusion的部分用的是 ElasticFusion: Dense SLAM without a pose graph 这篇文章实现了local loop clo ...
- 《Ray Tracing in One Weekend》——Chapter 5: Surface normals and multiple objects
总结<Ray Tracing in One Weekend>全文 第一部分:学习总结 问题十四:怎么可视化球的法向量 问题十七:怎么用ray tracing画多个球? 中途又补充了点C++ ...
- [转]使用Cool Edit Pro和Adobe Audition消除原唱
用Cool Edit Pro消除原唱,方法实际上可以说很简单,然而要想把它做的很完美还是得下点功夫. 我这里说的"消原唱"只是Cool Edit Pro菜单中的一个独立功能,选择并 ...
- D23:Multiple of 3 Or 5(3或5的倍数,翻译+题解)
原题:OpenJudge - 23:Multiple of 3 Or 5 翻译: 描述:求[1,N]里有多少个整数是3或5的倍数: 输入:一个不超过100000的正整数N: 输出:一个整数. 代码: ...
- komodo edit 支持java么_Komodo Edit for Mac(多语言集成开发环境)
原标题:Komodo Edit for Mac(多语言集成开发环境) Komodo Edit for mac是一个跨平台支持多种程序语言的Integrated Development Environm ...
- BDB 入门篇 第5章 Saving and Retrieving Objects 保存和检索对象
第5章 Saving and Retrieving Objects 保存和检索对象 要将对象存储在EntityStore中,您必须对类进行相应的注解,然后将其存储 PrimaryIndex.put() ...
- 【转】经济计量学软件包Eviews快速使用
Eviews软件使用 经济计量学软件包Eviews快速使用 袁建文 整理编写 内容导引: 一.启动软件包 附录:经济计量学软件包Eviews简介 二.创建工作文件 一.经济计量学软件包的主要功能 三. ...
最新文章
- Design Pattern - Adapter(C#)
- 关于IFRAME的一些小应用
- mysql 代码执行时间_mysql 显示SQL语句执行时间的代码
- callablestatement.setstring会不会将字符串trim_Java String:重要到别人只能当老二的字符串类
- 【CodeForces - 789D】Weird journey(思维,图的性质,tricks,有坑)
- python3纵向输出字符串_笔记||Python3之字符串格式化输出
- spring整合ehcache
- 【以前的空间】vijos 1720 阿狸的打字机
- 精通CSS:高级Web标准解决方案(第2版)--前言
- kotlin_Kotlin
- 凸优化第二章凸集 2.6对偶锥与广义不等式
- UG NX二次开发(C#)-分析-测量体对象的体积
- SAP中的输入历史记录设定
- 硬盘服务器与硬盘阵列,磁盘阵列和硬盘的区别是什么
- C语言经典案例——第六章 字符串
- python数据类型的转化和获取
- Conflux一周年 | 25分钟 VS 以太坊7个月,伍爷の硬核庆生
- 选择勤哲Excel服务器做企业管理系统ERP的经验之谈
- JVM内置函数intrinsics简介
- 行业报告免费下载-干货!68份营销行业报告分享
热门文章
- 爬虫 | 正则表达式提取腾讯教育新闻链接及图片链接
- 初学者编写python用什么软件好_初学者编写python用什么软件
- 计算机中iis6.0配置步骤,Win2003 IIS6.0 安装方法 图文详细教程
- python与pyqt5_【Python开发】PyQt5应用与实践
- 四、HTTP响应报文格式
- C++知识点10——函数指针
- css数字发光,每日CSS_发光文本效果
- int类型年月怎么区间查询_LeetCode 力扣官方题解 | 57.插入区间
- python跟java 效率_Python与Java:哪个更好,如何选择?
- android简单app实例_Android安卓小项目实战视频教程集锦