{"id":22173259,"url":"https://github.com/digao-dalpiaz/dzminitable","last_synced_at":"2026-02-04T04:03:39.305Z","repository":{"id":47132747,"uuid":"167092332","full_name":"digao-dalpiaz/DzMiniTable","owner":"digao-dalpiaz","description":"Delphi non-visual component to handle small dynamic table stored as plain text","archived":false,"fork":false,"pushed_at":"2021-09-19T23:11:15.000Z","size":4491,"stargazers_count":17,"open_issues_count":0,"forks_count":6,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-24T17:53:19.182Z","etag":null,"topics":["component","delphi","fields","pascal","records","table"],"latest_commit_sha":null,"homepage":null,"language":"Pascal","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/digao-dalpiaz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-23T01:02:23.000Z","updated_at":"2024-05-18T21:47:12.000Z","dependencies_parsed_at":"2022-08-18T21:51:56.735Z","dependency_job_id":null,"html_url":"https://github.com/digao-dalpiaz/DzMiniTable","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/digao-dalpiaz/DzMiniTable","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digao-dalpiaz%2FDzMiniTable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digao-dalpiaz%2FDzMiniTable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digao-dalpiaz%2FDzMiniTable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digao-dalpiaz%2FDzMiniTable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/digao-dalpiaz","download_url":"https://codeload.github.com/digao-dalpiaz/DzMiniTable/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digao-dalpiaz%2FDzMiniTable/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262470969,"owners_count":23316594,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["component","delphi","fields","pascal","records","table"],"created_at":"2024-12-02T07:31:31.369Z","updated_at":"2026-02-04T04:03:39.254Z","avatar_url":"https://github.com/digao-dalpiaz.png","language":"Pascal","funding_links":["https://ko-fi.com/C0C53LVFN"],"categories":[],"sub_categories":[],"readme":"# DzMiniTable\n\n## Delphi non-visual component to handle small dynamic table stored as plain text\n\n![Delphi Supported Versions](https://img.shields.io/badge/Delphi%20Supported%20Versions-XE3..11-blue.svg)\n![Platforms](https://img.shields.io/badge/Platforms-Win32%20and%20Win64-red.svg)\n![Auto Install](https://img.shields.io/badge/-Auto%20Install%20App-orange.svg)\n![VCL and FMX](https://img.shields.io/badge/-VCL%20and%20FMX-lightgrey.svg)\n\n[![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/C0C53LVFN)\n\nPlease, checkout my new component [DzXMLTable](https://github.com/digao-dalpiaz/DzXMLTable), it's a new concept of this component, storing data in XML format.\n\n- [What's New](#whats-new)\n- [Component Description](#component-description)\n- [Installing](#installing)\n- [Published Properties](#published-properties)\n- [Public Properties](#public-properties)\n- [Procedures/Functions](#proceduresfunctions)\n\n## What's New\n\n- 09/12/2021 (Version 1.8)\n\n   - Delphi 11 auto-install support.\n\n\u003cdetails\u003e\n  \u003csummary\u003eClick here to view the entire changelog\u003c/summary\u003e\n\n- 03/13/2021 (Version 1.7)\n\n   - Removed CompInstall.exe from component sources due to AV false positive warning (now you can get it directly from CompInstall repository).\n\n- 02/01/2021 (Version 1.6)\n\n   - Removed Delphi XE2 from the list of environments as it was never possible to compile in this version.\n\n- 12/18/2020 (Version 1.5)\n\n   - Updated Component Installer app (Fixed call to rsvars.bat when Delphi is installed in a path containing spaces characters).\n\n- 10/31/2020 (Version 1.4)\n\n   - Included Delphi 10.4 auto-install support.\n\n- 10/27/2020 (Version 1.3)\n\n   - Fixed previous Delphi versions (at least on XE2, XE3, XE4 and XE5) package tag. It was causing package compilation error.\n\n- 10/26/2020 (Version 1.2)\n\n   - Updated CompInstall to version 2.0 (now supports GitHub auto-update)\n\n- 10/09/2020 (Version 1.1)\n\n   - New methods to search data\n\n- 05/03/2020\n\n   - Updated CompInstall to version 1.2\n\n- 02/11/2019\n\n   - Include auto install app\n\n- 02/08/2019\n\n   - Component renamed. Please full uninstall previous version before install this version. :warning:\n\n- 02/07/2019\n\n   - Add Win64 support (library folders changed!) :warning:\n   \n\u003c/details\u003e\n\n## Component Description\n\nWhen you are working on your software project, you always need to store some data into a INI file or some text file, as a configuration file or other information.\n\nSo, the options you have is INI file, or plain text. And almost always you need a table with some fields.\n\nIn a plain text, you can use one record per line, and separate fields using tab character, or pipe character, or another one. But you have some problems with this method: you need to take care about the separator char, not using it at fields value; and you have a biggest problem: in a future version, if you need to add a column, you lose the compatibility at this file when there are already data stored.\n\nIf you are working with INI file, you can specify the field names, but even that, you have problems to store one record per section, and is difficult to reorder records, delete records and name the record.\n\nBut don't worry, here is the solution.\n\nThe MiniTable is a non-visual component where you can store records with fields and values, and you can name the field, so you don't need to worry at future versions. You can add new fields at any time, just reading and writing them.\n\n## Installing\n\n### Auto install\n\n1. Download Component Installer from: https://github.com/digao-dalpiaz/CompInstall/releases/latest\n2. Put **CompInstall.exe** into the component repository sources folder.\n3. Close Delphi IDE and run **CompInstall.exe** app.\n\n### Manual install\n\n1. Open **DzMiniTable** package in Delphi.\n2. Ensure **Win32** Platform and **Release** config are selected.\n3. Then **Build** and **Install**.\n4. If you want to use Win64 platform, select this platform and Build again.\n5. Add sub-path Win32\\Release to the Library paths at Tools\\Options using 32-bit option, and if you have compiled to 64 bit platform, add sub-path Win64\\Release using 64-bit option.\n\nSupports Delphi XE3..Delphi 11\n\n## Published Properties\n\n`AutoSave: Boolean` = Enables auto save to specified FileName at any method that writes any change to the table\n\n`FileName: String` = Specifies the full file name to Open and Save the table\n\n`JumpOpen: Boolean` = When this property is enabled, if the file does not exist at Open method, the table will be loaded empty without raise any exception.\n\n## Public Properties\n\n`Lines: TStringList` = Allows you to change the stored table manually. **You should never change this TStringList.**\n\n`MemString: String` = Allows you to load the table directly from a string, and store the table to a string. This is useful when you are storing the table in a database blob file.\n\n`SelIndex: Integer` = Returns the current selected index (read-only property)\n\n`Count: Integer` = Returns the record count of the table (read-only property)\n\n`F[FieldName: String]: Variant` = Read/write a field value at current selected record. The FieldName is case-insensitive.\nIf you are reading field value and the field does not exist, the result is an empty string.\n\n## Procedures/Functions\n\n```delphi\nprocedure SelReset;\n```\nResets the selection of record to none. You can use this method to initialize an iteration of record, ensuring the selected record is reseted.\n\n```delphi\nfunction InRecord: Boolean;\n```\nReturns true if there is a record selected\n\n```delphi\nprocedure Open;\n```\nLoad the table from file specified at FileName property\n\n```delphi\nprocedure Save;\n```\nSave the table to file specified at FileName property\n\n```delphi\nprocedure EmptyTable;\n```\nClear all data in the table\n\n```delphi\nprocedure EmptyRecord;\n```\nClear all data in the current selected record\n\n```delphi\nfunction IsEmpty: Boolean;\n```\nReturns true if the table is empty\n\n```delphi\nprocedure Select(Index: Integer);\n```\nSelect the record by index position. When you select a record, all its fields stays stored at internal memory, so you can read and write the fields value using `F` property.\n\n```delphi\nprocedure First;\n```\nSelect the first record in the table\n\n```delphi\nprocedure Last;\n```\nSelect the last record in the table\n\n```delphi\nfunction Next: Boolean;\n```\nSelect the next record in the table, based in the current index position. This method is useful to iterate all record. See example below:\n\n```delphi\nDzMiniTable.SelReset;\nwhile MiniTable.Next do\nbegin\n  ListBox.Add(DzMiniTable.F['Name']+' / '+MiniTable.F['Phone']);\nend;\n```\n\n```delphi\nprocedure New;\n```\nCreate a new record at the end of the table position and select it, so you can immediately start write fields.\n\n```delphi\nprocedure Insert(Index: Integer);\n```\nInsert a new record at the index position and select it, so you can immediately start write fields.\n\n```delphi\nprocedure Post;\n```\nWrites all change in the current record to the table. You don't need to start editing of the record. See example below:\n\n```delphi\nDzMiniTable.New;\nDzMiniTable.F['Name'] := 'John';\nDzMiniTable.F['Phone'] := '1111-2222';\nDzMiniTable.Post;\n```\nor:\n```delphi\nDzMiniTable.Select(3);\nDzMiniTable.F['Phone'] := '1111-2222';\nDzMiniTable.Post;\n```\n\n```delphi\nprocedure Delete;\n```\nDelete the current selected record\n\n```delphi\nprocedure MoveDown;\n```\nMove the current record to one index down\n\n```delphi\nprocedure MoveUp;\n```\nMove the current record to one index up\n\n```delphi\nfunction FindIndex(const FieldName: string; const Value: Variant): Integer;\n```\nFind any field value on all records, returning record index position.\n\n```delphi\nfunction Locate(const FieldName: string; const Value: Variant): Boolean;\n```\nFind any field value on all records, returning true if record found, and **positioning it as current record**.\nIf no record is found, the current position will not be changed.\n\n```delphi\nfunction ContainsValue(const FieldName: string; const Value: Variant): Boolean;\n```\nFind any field value on all records, returning true if record found.\n\n```delphi\nfunction FieldExists(const FieldName: String): Boolean;\n```\nReturns true if the FieldName exists at current selected record.\n\n```delphi\nfunction ReadDef(const FieldName: String; const Default: Variant): Variant;\n```\nThis functions is the same as the F property, but here you can specify a default value when the Field does not exist in the record.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigao-dalpiaz%2Fdzminitable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdigao-dalpiaz%2Fdzminitable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigao-dalpiaz%2Fdzminitable/lists"}