Opens a read/write session. This session automatically tracks changes made to any objects that were retrieved within this session.
It also tracks the newly created and to-be-deleted objects. All saves occur when the session is disposed.
If any exceptions occurred before the session is closed, no changes are applied.
This system makes it easy to perform transactional changes and prevents any partial changes due to errors before the session is disposed.
Namespace: Ingeniux.CMS
Assembly: Ingeniux.CMS.CSAPI (in Ingeniux.CMS.CSAPI.dll) Version: 9.0.565.0 (9.0.565)
Syntax
Parameters
- user
- Type: Ingeniux.CMSIReadonlyUser
The user to open the session. All changes must occur via this user account.
Return Value
Type: IUserWriteSessionThe read/write session.
Remarks
Examples
C#
IReadonlyUser currentUser = store.GetStartingUser(@"yourfirm\youruserid"); using (IUserSession session = store.OpenWriteSession(currentUser)) { ...... }
See Also