Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
BO のフィールドを (Controller クラスで) 保存するときにデフォルト値を割り当てたい場合、C# と xaf を使用してこれを実現するにはどうすればよいですか? 関連するイベントはどれですか?
OnSaving メソッドを使用できます
public class MyObject:XPObject { protected override void OnSaving() { if(this.Session.IsNewObject(this)) //SetDefaultValues base.OnSaving(); } }