Course 10 / Lecture 10:

Automatically generated grids and forms

One of the best things in Ozeki is that you can automatically generate forms, and grids for your data classes. If your data is stored in an Item Manager (Lecture 9), you can display a grid and/or a form on the Graphical User Interface of your program automatically with a single line of code.


Task #1:

Create a grid to manage license plates!

The following video shows you how to generate your grid using the previously created data class and item manager through the singleton instance of the AllowedLicensePlateManager class.

Task #2:

Use the managed data in the barrier control code!

If the NumberPlateDetected event has been occured, we need to check whether the detected license can be found in the item manager of the AllowedLicensePlate or not. We can verify it through the count method of the item manager.

Task #3:

Create a data class to store detections!

The following video shows how to create a new data class that will be responsible for storing detected license plates. Use the [OzA_List] attribute to show the columns in the grid.

Task #4:

Create an ItemManager for detections!

From the following video you can learn how to save your data to your storage. In this case, an xml file will be generated in the c:\Program Files\Ozeki\Ozeki10\Data\BarrierControl folder with the DetectedLicense_ prefix. It will keep the license plate number, a timestamp, and a checkbox which shows you that the license plate is allowed or not.

Task #5:

Create a grid to show detections!

Now you need to use the Admin method of the singleton instance of the MyDetectionManager class to show the detected licenses in a list. If you use the OzAdminType.Grid type for the Admin method's parameter, only a list will be generate, without a form. Furthermore you can see how to add the page to the AppSiteMap and to the Toolbar tools.

Task #6:

Save detected license plates to MyDetectionManager!

You need to use the Add method of the MyDetectionManager instance to add the detected license plates to your item manager.

Task #7:

Test your code!

The following video demonstrates the developed barrier control app. You can see that the barrier control system opens the barrier if a car arrives with an allowed license plate number.

More information


Next


Copyright © 2000- |Ozeki Ltd | info@ozekirobot.com |
Page: 6270 | 79.99.42.43 | Login