-
Notifications
You must be signed in to change notification settings - Fork 0
Instance Editor and Grid
There are two editors that you can use to edit instances of an entity:
-
The Instance Editor, accessible using the entity Ribbon Bar or the design surface context menu “Add Instance” item.
-
The instance Grid, accessible only using the entity Ribbon Bar.
When you click on “Add Instance”, you will be presented a resizable dialog box like this one:
This dialog box has a “Values” tab that contains a property grid that allows you to modify the instance properties, according to the current entity properties definition. Each line is associated with an entity property and the editor is related to the property type. In the example above, since the “VehicleStatus” property type is an enumeration defined in the project, the editor is a drop-down list containing the list of values defined in the enumeration type.
The “Unmapped Values” tab corresponds to instance values that have been added previously for which there’s no corresponding property anymore. These unmapped values can only be seen and removed.
After the instance has been added, it’s displayed in the entity shape, in the “Instances” folder, like this:
By default, the instance is displayed using the entity key instance value (“1” in this example). This can be changed as shown in the following image:
You must first select the property that will be used to display instances, then go to the Visual Studio property grid and change the “Is Entity Display” attribute to True. Now the instance tree view item should use the value of the property that is defined as the “entity display” (in our example, the “SerialNumber” property has the “19662403” string value).
When you click on “Instances Grid” in the Ribbon Bar with an entity selected, you will be presented a resizable dialog box like this one:
This is like a spreadsheet viewer and editor over the list of instances for the selected entity. The grid editors are the same as used in the Instance Editor.
You can use the keyboard like in other grids to edit instances: arrows keys to navigate between cell, F2 to enter edit mode, F4 to open the editor if any, etc.
Note: the editor for instance value of type System.Guid (or guid) allows you to create new guids, or use the empty guid, or increment the current guid:
- Introduction
- Architect Guide
- Concepts
- Using Visual Studio
- Overview
- Creating a CodeModeler Project
- Visual Environment
- Project Hierarchy
- Design Surface
- Customizing Design Surfaces
- Ribbon Bar
- Property Grid
- Member Format Expressions
- Model Grid
- Method Editor
- View Editor
- Instance Editor and Grid
- Resources Editor
- Inferred Model Viewer
- Building
- Project Physical Layout
- Source Control Support
- Generating
- Aspect Oriented Design (AOD)
- Developer Guide
- The Business Object Model (BOM)
- CodeModeler Query Language (CMQL)
- Starting Guide - Tutorial
- Upgrade From CFE