update 20251008

This commit is contained in:
Stefan Hutter
2025-10-08 17:23:08 +02:00
parent 2773ca3baa
commit 6b7de9389c
206 changed files with 855857 additions and 116 deletions

View File

@@ -14,6 +14,8 @@ using Syncfusion.Windows.Forms.Spreadsheet.Commands;
using OnDoc.UICintrols;
using OnDoc.UIControls;
using System.Linq.Expressions;
using System.Diagnostics;
using Windows.Globalization;
@@ -124,6 +126,31 @@ namespace OnDoc
// // MyForm = new Start();
// Application.Run(MyForm);
//Versionsupdate
if (AppParams.check_for_updates)
{
string filename = AppParams.updatepath + @"\version.txt";
string version = "";
if (System.IO.File.Exists(filename))
{
version = System.IO.File.ReadAllText(filename);
if (version != AppParams.assemblyversion)
{
//MessageBox.Show("Start Updater");
//MessageBox.Show(Application.StartupPath + @"\OnDocUpdate\OnDocUpdate.exe");
//MessageBox.Show(Application.StartupPath + @"\OnDocUpdate\");
//MessageBox.Show(Application.StartupPath);
//MessageBox.Show(Application.StartupPath + @"\ondoc.exe");
ProcessStartInfo startInfo = new ProcessStartInfo(Application.StartupPath + @"\OnDocUpdate\OnDocUpdate.exe");
startInfo.WindowStyle = ProcessWindowStyle.Normal;
startInfo.WorkingDirectory = Application.StartupPath + @"\OnDocUpdate\";
startInfo.Arguments = version + " " + AppParams.updatepath + " " + Application.StartupPath + " " + Application.StartupPath + @"\ondoc.exe";
Process.Start(startInfo);
return;
}
}
}
AppParams.StartApp = true;
Application.Run(new Start());
AppParams.StartApp = false;