Testing database connection.

This commit is contained in:
Fey 2026-02-01 16:40:44 +01:00
parent c83d69a200
commit 20ee473fda
4 changed files with 427 additions and 307 deletions

View File

@ -5,8 +5,9 @@ using System.Text;
using System.Threading.Tasks;
namespace Voile.Patchouli.Data
{
public interface IVoileDataStorage
{
}
{
public interface IVoileDataStorage
{
bool Ping();
}
}

View File

@ -1,6 +1,7 @@
using Microsoft.Data.Sqlite;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@ -12,7 +13,7 @@ namespace Voile.Storage.Sqlite
{
[VoilePlugin]
[VoilePluginId(3)]
[DisplayName("SQLite")]
[Voile.Patchouli.Reflection.DisplayName("SQLite")]
public class SqliteDataStorageFactory : IVoileDataStorageFactory
{
public IVoileDataStorage CreateDataStorage()
@ -20,6 +21,7 @@ namespace Voile.Storage.Sqlite
throw new NotImplementedException();
}
[Description("The path to the SQLite database file. If it doesn't exist, it will be created")]
public string FilePath { get; set; }
private SqliteConnectionStringBuilder scsb;

View File

@ -48,11 +48,15 @@
tabPagePickDataStorage = new TabPage();
labelDataStorageHint = new Label();
label5 = new Label();
tabPageConfigureDataStorage = new TabPage();
dbSettingsErrorLabel = new Label();
dbTestTrafficLight = new PictureBox();
dbTestButton = new Button();
dbSettingsPropertyGrid = new PropertyGrid();
label6 = new Label();
buttonNext = new Button();
buttonBack = new Button();
openFileDialogCertificate = new OpenFileDialog();
tabPageConfigureDataStorage = new TabPage();
label6 = new Label();
((System.ComponentModel.ISupportInitialize)pictureBox1).BeginInit();
tabControl1.SuspendLayout();
tabPageWelcome.SuspendLayout();
@ -60,6 +64,7 @@
((System.ComponentModel.ISupportInitialize)pictureBox2).BeginInit();
tabPagePickDataStorage.SuspendLayout();
tabPageConfigureDataStorage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)dbTestTrafficLight).BeginInit();
SuspendLayout();
//
// pictureBox1
@ -265,6 +270,64 @@
label5.TabIndex = 0;
label5.Text = resources.GetString("label5.Text");
//
// tabPageConfigureDataStorage
//
tabPageConfigureDataStorage.Controls.Add(dbSettingsErrorLabel);
tabPageConfigureDataStorage.Controls.Add(dbTestTrafficLight);
tabPageConfigureDataStorage.Controls.Add(dbTestButton);
tabPageConfigureDataStorage.Controls.Add(dbSettingsPropertyGrid);
tabPageConfigureDataStorage.Controls.Add(label6);
tabPageConfigureDataStorage.Location = new Point(4, 24);
tabPageConfigureDataStorage.Name = "tabPageConfigureDataStorage";
tabPageConfigureDataStorage.Size = new Size(348, 384);
tabPageConfigureDataStorage.TabIndex = 3;
tabPageConfigureDataStorage.Text = "Configure Date Storage";
tabPageConfigureDataStorage.UseVisualStyleBackColor = true;
//
// dbSettingsErrorLabel
//
dbSettingsErrorLabel.AutoSize = true;
dbSettingsErrorLabel.Location = new Point(3, 70);
dbSettingsErrorLabel.Name = "dbSettingsErrorLabel";
dbSettingsErrorLabel.Size = new Size(77, 15);
dbSettingsErrorLabel.TabIndex = 9;
dbSettingsErrorLabel.Text = "TEST_RESULT";
//
// dbTestTrafficLight
//
dbTestTrafficLight.Image = Properties.Resources.SETUPAPI_18_1_32x32x4;
dbTestTrafficLight.Location = new Point(214, 70);
dbTestTrafficLight.Name = "dbTestTrafficLight";
dbTestTrafficLight.Size = new Size(32, 32);
dbTestTrafficLight.TabIndex = 8;
dbTestTrafficLight.TabStop = false;
//
// dbTestButton
//
dbTestButton.Location = new Point(252, 70);
dbTestButton.Name = "dbTestButton";
dbTestButton.Size = new Size(93, 32);
dbTestButton.TabIndex = 2;
dbTestButton.Text = "Test Settings";
dbTestButton.UseVisualStyleBackColor = true;
dbTestButton.Click += dbTestButton_Click;
//
// dbSettingsPropertyGrid
//
dbSettingsPropertyGrid.Location = new Point(3, 108);
dbSettingsPropertyGrid.Name = "dbSettingsPropertyGrid";
dbSettingsPropertyGrid.Size = new Size(342, 273);
dbSettingsPropertyGrid.TabIndex = 1;
//
// label6
//
label6.AutoSize = true;
label6.Location = new Point(3, 0);
label6.Name = "label6";
label6.Size = new Size(38, 15);
label6.TabIndex = 0;
label6.Text = "label6";
//
// buttonNext
//
buttonNext.Enabled = false;
@ -293,25 +356,6 @@
openFileDialogCertificate.Filter = "X.509 Certificate (*.cer)|*.cer";
openFileDialogCertificate.Title = "Open Voile License File";
//
// tabPageConfigureDataStorage
//
tabPageConfigureDataStorage.Controls.Add(label6);
tabPageConfigureDataStorage.Location = new Point(4, 24);
tabPageConfigureDataStorage.Name = "tabPageConfigureDataStorage";
tabPageConfigureDataStorage.Size = new Size(348, 384);
tabPageConfigureDataStorage.TabIndex = 3;
tabPageConfigureDataStorage.Text = "Configure Date Storage";
tabPageConfigureDataStorage.UseVisualStyleBackColor = true;
//
// label6
//
label6.AutoSize = true;
label6.Location = new Point(3, 0);
label6.Name = "label6";
label6.Size = new Size(38, 15);
label6.TabIndex = 0;
label6.Text = "label6";
//
// FirstRunWizard
//
AutoScaleDimensions = new SizeF(7F, 15F);
@ -338,6 +382,7 @@
tabPagePickDataStorage.PerformLayout();
tabPageConfigureDataStorage.ResumeLayout(false);
tabPageConfigureDataStorage.PerformLayout();
((System.ComponentModel.ISupportInitialize)dbTestTrafficLight).EndInit();
ResumeLayout(false);
}
@ -367,5 +412,9 @@
private Label labelDataStorageHint;
private TabPage tabPageConfigureDataStorage;
private Label label6;
private PropertyGrid dbSettingsPropertyGrid;
private Button dbTestButton;
private PictureBox dbTestTrafficLight;
private Label dbSettingsErrorLabel;
}
}

View File

@ -10,304 +10,372 @@ using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using Voile.Patchouli.Data;
using Voile.Patchouli.Reflection;
using Voile.Properties;
namespace Voile
{
public partial class FirstRunWizard : Form
{
public FirstRunWizard()
{
InitializeComponent();
DisplayTabPage(0);
}
private TabPage[] allPages;
private int currentTabPage;
private Stack<int> pastPages;
private bool beginnerMode;
private FileInfo licenceCertificateFileInfo;
private byte[] licenseBuffer;
private int licenseState;
private X509Certificate licenseCertificate;
private bool sharewareMode;
private VoilePluginInfo selectedDataStorage;
public void DisplayTabPage(int target, bool isGoingBack = false)
{
if (pastPages == null)
pastPages = new Stack<int>();
else
pastPages.Push(target);
if (allPages == null)
{
allPages = new TabPage[tabControl1.TabPages.Count];
for (int i = 0; i < tabControl1.TabPages.Count; i++)
{
allPages[i] = tabControl1.TabPages[i];
}
}
tabControl1.TabPages.Clear();
tabControl1.TabPages.Add(allPages[target]);
currentTabPage = target;
RefreshView();
}
void RefreshView()
{
buttonBack.Enabled = false;
buttonNext.Enabled = false;
if (pastPages != null)
{
if (pastPages.Count > 0)
{
buttonBack.Enabled = true;
}
}
switch (currentTabPage)
{
case 0:
beginnerMode = radioButtonAmBegginer.Checked;
buttonNext.Enabled = radioButtonAmBegginer.Checked || radioButtonAmExpert.Checked;
break;
case 1:
//Lizenzstatus validieren.
buttonValidateLicense.Enabled = ((licenceCertificateFileInfo != null) & radioButtonHasLicense.Checked);
buttonLoadLicenseFile.Enabled = radioButtonHasLicense.Checked;
pictureBox2.Visible = radioButtonHasLicense.Checked;
if (pictureBox2.Visible)
{
switch(licenseState)
{
case 0: //Noch nichts geladen.
pictureBox2.Image = Resources.SETUPAPI_18_1_32x32x4; //Fragezeichen
break;
case 1: //Root cert konnte nicht geladen werden.
case 2: //Lizenz file konnte nicht geladen werden.
case 3: //Lizenzzertifikat wurde nicht von sophia.net ausgestellt.
case 4: //Lizennzertifikat enthält keine sophia.net extensions
case 5: //sophia.net extension ist leer
case 7: //sophia.net extension hat ungültige länge
pictureBox2.Image = Resources.TRFFC10C_1_32x32x4; //rote Ampel
break;
case 6: //gültige lizenz
pictureBox2.Image = Resources.TRFFC10A_1_32x32x4; //grüne Ampel
break;
case 8:
default:
pictureBox2.Image = Resources.iblicense_133_1_32x32x4; //Ausrufezeichen
licenseState = 8;
break;
}
}
//Können wir weiter machen?
sharewareMode = radioButtonNoLicense.Checked;
buttonNext.Enabled = (sharewareMode) | (licenseState == 6);
break;
case 2:
labelDataStorageHint.Text = " ";
if (!dataStorageRadioButtonsGenerated)
GenerateDataStorageRadioButtons();
{
public partial class FirstRunWizard : Form
{
public FirstRunWizard()
{
InitializeComponent();
DisplayTabPage(0);
}
//TODO: Hier zusätzlich Lizenzvalidierung einfügen.
buttonNext.Enabled = selectedDataStorage != null;
break;
default:
MessageBox.Show("Could not find handler for the current tab page.");
return;
}
}
private TabPage[] allPages;
private int currentTabPage;
private Stack<int> pastPages;
private bool beginnerMode;
private FileInfo licenceCertificateFileInfo;
private byte[] licenseBuffer;
private int licenseState;
private X509Certificate licenseCertificate;
private bool sharewareMode;
private VoilePluginInfo selectedDataStorage;
private IVoileDataStorageFactory voileDataStorageFactory;
private bool dataStorageConnectionSucessful;
public void DisplayTabPage(int target, bool isGoingBack = false)
{
if (pastPages == null)
pastPages = new Stack<int>();
else
pastPages.Push(target);
if (allPages == null)
{
allPages = new TabPage[tabControl1.TabPages.Count];
for (int i = 0; i < tabControl1.TabPages.Count; i++)
{
allPages[i] = tabControl1.TabPages[i];
}
}
tabControl1.TabPages.Clear();
tabControl1.TabPages.Add(allPages[target]);
currentTabPage = target;
RefreshView();
}
void RefreshView()
{
buttonBack.Enabled = false;
buttonNext.Enabled = false;
if (pastPages != null)
{
if (pastPages.Count > 0)
{
buttonBack.Enabled = true;
}
}
switch (currentTabPage)
{
case 0:
beginnerMode = radioButtonAmBegginer.Checked;
buttonNext.Enabled = radioButtonAmBegginer.Checked || radioButtonAmExpert.Checked;
break;
case 1:
//Lizenzstatus validieren.
buttonValidateLicense.Enabled = ((licenceCertificateFileInfo != null) & radioButtonHasLicense.Checked);
buttonLoadLicenseFile.Enabled = radioButtonHasLicense.Checked;
pictureBox2.Visible = radioButtonHasLicense.Checked;
if (pictureBox2.Visible)
{
switch (licenseState)
{
case 0: //Noch nichts geladen.
pictureBox2.Image = Resources.SETUPAPI_18_1_32x32x4; //Fragezeichen
break;
case 1: //Root cert konnte nicht geladen werden.
case 2: //Lizenz file konnte nicht geladen werden.
case 3: //Lizenzzertifikat wurde nicht von sophia.net ausgestellt.
case 4: //Lizennzertifikat enthält keine sophia.net extensions
case 5: //sophia.net extension ist leer
case 7: //sophia.net extension hat ungültige länge
pictureBox2.Image = Resources.TRFFC10C_1_32x32x4; //rote Ampel
break;
case 6: //gültige lizenz
pictureBox2.Image = Resources.TRFFC10A_1_32x32x4; //grüne Ampel
break;
case 8:
default:
pictureBox2.Image = Resources.iblicense_133_1_32x32x4; //Ausrufezeichen
licenseState = 8;
break;
}
}
//Können wir weiter machen?
sharewareMode = radioButtonNoLicense.Checked;
buttonNext.Enabled = (sharewareMode) | (licenseState == 6);
break;
case 2:
labelDataStorageHint.Text = " ";
if (!dataStorageRadioButtonsGenerated)
GenerateDataStorageRadioButtons();
//TODO: Hier zusätzlich Lizenzvalidierung einfügen.
buttonNext.Enabled = selectedDataStorage != null;
break;
case 3:
dbSettingsErrorLabel.Text = "";
if (voileDataStorageFactory == null)
{
dbSettingsPropertyGrid.SelectedObject = selectedDataStorage.GetPluginInstance();
}
break;
default:
MessageBox.Show("Could not find handler for the current tab page.");
return;
}
}
private bool dataStorageRadioButtonsGenerated;
private RadioButton[] dataStorageRadioButtons;
private void GenerateDataStorageRadioButtons()
{
VoilePluginManager pluginManager = VoilePluginManager.GetInstance();
IReadOnlyList<VoilePluginInfo> dataStoragePlugins = pluginManager.GetDataStorages();
dataStorageRadioButtons = new RadioButton[dataStoragePlugins.Count];
int top = labelDataStorageHint.Top;
top += labelDataStorageHint.Height;
int left = labelDataStorageHint.Left;
for (int i = 0; i < dataStorageRadioButtons.Length; i++)
{
RadioButton childRadioButton = new RadioButton();
childRadioButton.Parent = tabPagePickDataStorage;
private RadioButton[] dataStorageRadioButtons;
private void GenerateDataStorageRadioButtons()
{
VoilePluginManager pluginManager = VoilePluginManager.GetInstance();
IReadOnlyList<VoilePluginInfo> dataStoragePlugins = pluginManager.GetDataStorages();
dataStorageRadioButtons = new RadioButton[dataStoragePlugins.Count];
if (dataStoragePlugins[i].Incomplete)
childRadioButton.Enabled = false;
int top = labelDataStorageHint.Top;
top += labelDataStorageHint.Height;
string radioButtonLabel = dataStoragePlugins[i].DisplayName;
if (dataStoragePlugins[i].NeededEntitlement.HasValue)
radioButtonLabel += " (needs license)";
childRadioButton.AutoSize = true;
childRadioButton.Text = radioButtonLabel;
int left = labelDataStorageHint.Left;
if (selectedDataStorage != null)
childRadioButton.Checked = (selectedDataStorage.Id == dataStoragePlugins[i].Id);
for (int i = 0; i < dataStorageRadioButtons.Length; i++)
{
RadioButton childRadioButton = new RadioButton();
childRadioButton.Parent = tabPagePickDataStorage;
childRadioButton.Top = top;
childRadioButton.Left = left;
childRadioButton.Tag = dataStoragePlugins[i];
if (dataStoragePlugins[i].Incomplete)
childRadioButton.Enabled = false;
top += childRadioButton.Height;
string radioButtonLabel = dataStoragePlugins[i].DisplayName;
if (dataStoragePlugins[i].NeededEntitlement.HasValue)
radioButtonLabel += " (needs license)";
childRadioButton.AutoSize = true;
childRadioButton.Text = radioButtonLabel;
dataStorageRadioButtons[i] = childRadioButton;
if (selectedDataStorage != null)
childRadioButton.Checked = (selectedDataStorage.Id == dataStoragePlugins[i].Id);
childRadioButton.Top = top;
childRadioButton.Left = left;
childRadioButton.Tag = dataStoragePlugins[i];
top += childRadioButton.Height;
dataStorageRadioButtons[i] = childRadioButton;
dataStorageRadioButtons[i].CheckedChanged += OnDataStrorageSelected;
}
dataStorageRadioButtonsGenerated = true;
}
}
dataStorageRadioButtonsGenerated = true;
}
private void OnDataStrorageSelected(object? sender, EventArgs e)
{
RadioButton senderUnboxed = sender as RadioButton;
if (senderUnboxed == null)
throw new Voile.Common.VoileException("Could not unbox sender.");
VoilePluginInfo pluginInfo = senderUnboxed.Tag as VoilePluginInfo;
if (pluginInfo == null)
throw new Common.VoileException("Could not unbox plugin info");
RadioButton senderUnboxed = sender as RadioButton;
if (senderUnboxed == null)
throw new Voile.Common.VoileException("Could not unbox sender.");
selectedDataStorage = pluginInfo;
RefreshView();
}
VoilePluginInfo pluginInfo = senderUnboxed.Tag as VoilePluginInfo;
if (pluginInfo == null)
throw new Common.VoileException("Could not unbox plugin info");
private void radioButton3_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonAmBegginer_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonAmExpert_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonNoLicense_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void pictureBox2_Click(object sender, EventArgs e)
{
}
private void buttonNext_Click(object sender, EventArgs e)
{
if (currentTabPage == 0)
{
DisplayTabPage(1);
}
else if (currentTabPage == 1)
{
if (beginnerMode)
{
//TODO: Automatisch SQLite und Directory Storage auswählen
}
else
{
DisplayTabPage(2);
}
}
}
private void buttonLoadLicenseFile_Click(object sender, EventArgs e)
{
if (openFileDialogCertificate.ShowDialog() == DialogResult.OK)
{
licenceCertificateFileInfo = new FileInfo(openFileDialogCertificate.FileName);
licenseBuffer = File.ReadAllBytes(licenceCertificateFileInfo.FullName);
textBox1.Text = licenceCertificateFileInfo.FullName;
licenseState = 0;
pictureBox2.Image = Resources.SETUPAPI_18_1_32x32x4;
}
RefreshView();
}
private void buttonValidateLicense_Click(object sender, EventArgs e)
{
VoileContext voileContext = VoileContext.GetContext();
if (voileContext.SophiaNetRootCertificate == null)
{
try
{
byte[] sophianetCertBuffer = Resources.sophianet_cert;
voileContext.SophiaNetRootCertificate = SophiaNetDrmApi.ImportCertificate(sophianetCertBuffer);
}
catch (Exception ex)
{
licenseState = 1;
RefreshView();
return;
}
}
try
{
licenseCertificate = SophiaNetDrmApi.ImportCertificate(licenseBuffer);
}
catch (Exception f)
{
licenseState = 2;
RefreshView();
return;
}
bool certificateChainValid = SophiaNetDrmApi.ValidateCertificateChain(licenseCertificate, voileContext.SophiaNetRootCertificate);
if (!certificateChainValid)
{
licenseState = 3;
RefreshView();
return;
}
byte[] sophiaNetExtensionBuffer;
try
{
sophiaNetExtensionBuffer = SophiaNetDrmApi.GetSophiaNetExtensionFromCertificate(licenseCertificate);
}
catch (Exception g)
{
licenseState = 4;
RefreshView();
return;
}
if (sophiaNetExtensionBuffer.Length == 0)
{
licenseState = 5;
RefreshView();
return;
}
if (sophiaNetExtensionBuffer.Length % 16 != 0)
{
licenseState = 7;
RefreshView();
return;
}
licenseState = 6;
RefreshView();
return;
}
}
selectedDataStorage = pluginInfo;
RefreshView();
}
private void radioButton3_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonAmBegginer_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonAmExpert_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void radioButtonNoLicense_CheckedChanged(object sender, EventArgs e)
{
RefreshView();
}
private void pictureBox2_Click(object sender, EventArgs e)
{
}
private void buttonNext_Click(object sender, EventArgs e)
{
if (currentTabPage == 0)
{
//Wir sind auf der Willkommensseite, hier wird ausgewählt ob Anfänger oder Experte.
//Es wird nach der Lizenz gefragt
DisplayTabPage(1);
}
else if (currentTabPage == 1)
{
//Hier soll der Nutzer auswählen ob einfach oder schwierig.
if (beginnerMode)
{
//TODO: Automatisch SQLite und Directory Storage auswählen
}
else
{
DisplayTabPage(2);
}
}
else if (currentTabPage == 2)
{
//Hier soll der Nutzer auswählen, welche DB verwendet werden soll.
DisplayTabPage(3);
}
}
private void buttonLoadLicenseFile_Click(object sender, EventArgs e)
{
if (openFileDialogCertificate.ShowDialog() == DialogResult.OK)
{
licenceCertificateFileInfo = new FileInfo(openFileDialogCertificate.FileName);
licenseBuffer = File.ReadAllBytes(licenceCertificateFileInfo.FullName);
textBox1.Text = licenceCertificateFileInfo.FullName;
licenseState = 0;
pictureBox2.Image = Resources.SETUPAPI_18_1_32x32x4;
}
RefreshView();
}
private void buttonValidateLicense_Click(object sender, EventArgs e)
{
VoileContext voileContext = VoileContext.GetContext();
if (voileContext.SophiaNetRootCertificate == null)
{
try
{
byte[] sophianetCertBuffer = Resources.sophianet_cert;
voileContext.SophiaNetRootCertificate = SophiaNetDrmApi.ImportCertificate(sophianetCertBuffer);
}
catch (Exception ex)
{
licenseState = 1;
RefreshView();
return;
}
}
try
{
licenseCertificate = SophiaNetDrmApi.ImportCertificate(licenseBuffer);
}
catch (Exception f)
{
licenseState = 2;
RefreshView();
return;
}
bool certificateChainValid = SophiaNetDrmApi.ValidateCertificateChain(licenseCertificate, voileContext.SophiaNetRootCertificate);
if (!certificateChainValid)
{
licenseState = 3;
RefreshView();
return;
}
byte[] sophiaNetExtensionBuffer;
try
{
sophiaNetExtensionBuffer = SophiaNetDrmApi.GetSophiaNetExtensionFromCertificate(licenseCertificate);
}
catch (Exception g)
{
licenseState = 4;
RefreshView();
return;
}
if (sophiaNetExtensionBuffer.Length == 0)
{
licenseState = 5;
RefreshView();
return;
}
if (sophiaNetExtensionBuffer.Length % 16 != 0)
{
licenseState = 7;
RefreshView();
return;
}
licenseState = 6;
RefreshView();
return;
}
private void dbTestButton_Click(object sender, EventArgs e)
{
dataStorageConnectionSucessful = false;
if (voileDataStorageFactory == null)
{
IVoileDataStorageFactory newDs = selectedDataStorage.GetPluginInstance() as IVoileDataStorageFactory;
if (newDs == null)
{
dbSettingsErrorLabel.Text = "The selected plugin is not a Data Storage plugin. This is a bug in voile, please report it.";
dbTestTrafficLight.Image = Resources.TRFFC10C_1_32x32x4;
return;
}
voileDataStorageFactory = newDs;
}
IVoileDataStorage dataStorage = null;
try
{
dataStorage = voileDataStorageFactory.CreateDataStorage();
}
catch (Exception ex)
{
dbSettingsErrorLabel.Text = ex.Message;
dbTestTrafficLight.Image = Resources.TRFFC10C_1_32x32x4;
return;
}
try
{
Exception pingResult = dataStorage.Ping();
if (pingResult != null)
{
dbSettingsErrorLabel.Text = pingResult.Message;
dbTestTrafficLight.Image = Resources.TRFFC10C_1_32x32x4;
return;
}
}
catch (Exception ex2)
{
dbSettingsErrorLabel.Text = ex2.Message;
dbTestTrafficLight.Image = Resources.TRFFC10C_1_32x32x4;
return;
}
dbSettingsErrorLabel.Text = "Database connection sucessful!";
pictureBox2.Image = Resources.TRFFC10A_1_32x32x4; //grüne Ampel
dataStorageConnectionSucessful = true;
}
}
}