using OnDoc.Diverses; using OnDoc.DocMgmt; using OnDoc.Klassen; using System; using System.Collections.Generic; using System.Linq; using System.Runtime.Remoting.Channels; using System.Runtime.Remoting; using System.Threading; using System.Threading.Tasks; using System.Windows.Forms; using System.IO; using Syncfusion.Windows.Forms.Spreadsheet.Commands; namespace OnDoc { internal static class Program { /// Args /// shodoc:?partnernr=1000210&vorlagenr=125&interaktion=NO&showdoc=YES&funktion=Createdoc /// E:\Software-Projekte\OnDoc\EDK_Dateien\3bv.edk /// /// Der Haupteinstiegspunkt für die Anwendung. /// private static Mutex mutex = null; const string AppId = "OnDoc5094533C-A613-4889-A0E3-8C28C130C6AA)"; // Unique par application //static Start MyForm; /// [STAThread] static void Main(string[] args) { ExternalCall.sourceparam = ""; if (args.Length > 0) { if (args[0].ToString().ToUpper().Substring(args[0].ToString().Length - 4, 4) == ".EDK") { EDK_Data.Load_EDK_File(args[0]); } else { if (args[0].ToString().ToUpper().IndexOf("PARTNERNR") > 0) { AppParams.init(); //MessageBox.Show(AppParams.tempdir); string destfile = AppParams.tempdir + "tmpfile.tmp"; using (StreamWriter outputfile = new StreamWriter(destfile)) { outputfile.WriteLine(Uri.UnescapeDataString(args[0])); outputfile.Close(); } } else { MessageBox.Show("Die Übergabeparemeter '" + args[0].ToString()+"' sind ungültig","Aufruffehler",MessageBoxButtons.OK, MessageBoxIcon.Error); } } } const string appName = "OnDoc"; bool createdNew; mutex = new Mutex(true, appName, out createdNew); if (!createdNew) { return; } Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("Ngo9BigBOggjHTQxAR8/V1NBaF5cXmZCf1FpRmJGdld5fUVHYVZUTXxaS00DNHVRdkdnWXxccXVWR2VdUUZ3VkM="); AppParams.init(); // MyForm = new Start(); // Application.Run(MyForm); Application.Run(new Start()); } } }