This commit is contained in:
2026-04-17 14:55:32 -04:00
commit bc3ac1d4c9
18017 changed files with 4371742 additions and 0 deletions

View File

@@ -0,0 +1,43 @@
---
source_files:
- DataPRO/SLICEDBMerge/SLICEDBMerge/Program.cs
- DataPRO/SLICEDBMerge/SLICEDBMerge/Form1.cs
- DataPRO/SLICEDBMerge/SLICEDBMerge/Form1.Designer.cs
generated_at: "2026-04-17T15:54:57.534205+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "ed616bd81c400b4e"
---
# SLICEDBMerge Module Documentation
## 1. Purpose
SLICEDBMerge is a Windows Forms desktop application that provides a GUI for merging sensor databases. It allows users to select a source sensor database directory and a destination database directory, view the sensors in each, select specific sensors from the source, and merge them (along with their calibration data) into the destination database. The application is built using ComponentOne's C1FlexGrid for data display and depends on a proprietary `DTS.SensorDB` library for sensor database operations.
## 2. Public Interface
### `Program` class (static)
- **`void Main()`** - Application entry point. Configures visual styles and launches `Form1`.
### `Form1` class (public partial, inherits from `Form`)
#### Public Methods
- **`Form1()`** - Constructor. Calls `InitializeComponent()` to set up UI components.
#### Private Fields
- **`DTS.SensorDB.SensorDBTables _sourceDB`** - Holds the loaded source sensor database.
- **`DTS.SensorDB.SensorDBTables _destination`** - Holds the loaded destination sensor database.
#### Event Handlers
- **`void btnBrowse_Click(object sender, EventArgs e)`** - Opens a `FolderBrowserDialog` to select the source directory. On success, populates `tbSourceLocation.Text` and calls `LoadSourceDG()`.
- **`void btnDestinationBrowse_Click(object sender, EventArgs e)`** - Opens a `FolderBrowserDialog` to select the destination directory. On success, populates `tbDestination.Text` and calls `LoadDestinationDG()`.
- **`void button1_Click(object sender, EventArgs e)`** - Executes the merge operation. Iterates through `dgSource` rows, and for each selected row (where column index 1 is `true`), adds the `SensorData` to `_destination`, saves, retrieves the latest calibration via `_sourceDB.GetLatestCalibrationBySerialNumber()`, adds the calibration, and saves again. Collects errors and displays them in a message box. Refreshes the destination grid upon completion.
- **`void lbSelectAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)`** - Sets column index 1 to `true` for all rows in `dgSource` (starting at index 1).
- **`void lbInvertSelection_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)`** - Toggles the boolean value at column index 1 for all rows in `dgSource` (starting at index 1).
- **`void lbClearAll_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)`** - Sets column index

View File

@@ -0,0 +1,22 @@
---
source_files:
- DataPRO/SLICEDBMerge/SLICEDBMerge/Properties/Settings.Designer.cs
- DataPRO/SLICEDBMerge/SLICEDBMerge/Properties/AssemblyInfo.cs
- DataPRO/SLICEDBMerge/SLICEDBMerge/Properties/Resources.Designer.cs
generated_at: "2026-04-17T16:11:16.196370+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d21b1ed4cab61187"
---
# Properties
### Purpose
This module contains auto-generated Visual Studio designer files for the SliceDBMerge assembly. It provides strongly-typed access to application settings and localized resources, along with assembly metadata. This is standard .NET infrastructure code that should not be manually edited.
### Public Interface
**Settings** (internal sealed class)
- `static Settings Default { get; }` - Returns the singleton default instance of application settings, synchronized for thread safety.
**Resources