Update 20250107

This commit is contained in:
Stefan Hutter
2025-01-07 21:00:50 +01:00
parent 3b0a2b0527
commit af418d0114
706 changed files with 1054974 additions and 976 deletions

View File

@@ -567,9 +567,7 @@ namespace OnDocOffice
//word.ActiveDocument.Close(false);
Thread.Sleep(OfficeSleep);
//worddoc = word.Documents.Open(filename);
Logging.Logging.Debug("Word Open", "clsOffice", dokumentid);
Logging.Logging.Debug("Word befüllen", "clsOffice", dokumentid);
Logging.Logging.Debug("Word Open und Befüllen", "clsOffice", dokumentid);
Thread.Sleep(OfficeSleep);
if (worddoc.ProtectionType != Microsoft.Office.Interop.Word.WdProtectionType.wdNoProtection)
{
@@ -615,7 +613,7 @@ namespace OnDocOffice
dv.FieldName.ToString() == "TGEDKCursor" || dv.FieldName.ToString() == "TGEDKCursorB") { cursorpositionieren = true; }
}
catch { }
Logging.Logging.Debug(dv.TMBeginn.ToString() + " / " + dv.TMEnd.ToString(), dv.Value.ToString(), dokumentid);
// Logging.Logging.Debug(dv.TMBeginn.ToString() + " / " + dv.TMEnd.ToString(), dv.Value.ToString(), dokumentid);
dialogGenerate.add_progress((int)progressstep);
if (dv.TMBeginn.ToString() != "" && dv.TMEnd.ToString() == "")
{
@@ -631,7 +629,7 @@ namespace OnDocOffice
//pos = worddoc.Bookmarks[dv.TMBeginn.ToString()].Start;
//pos2 = word.Selection.End;
Logging.Logging.Debug(dv.TMBeginn.ToString(), "Selection-End", dokumentid);
// Logging.Logging.Debug(dv.TMBeginn.ToString(), "Selection-End", dokumentid);
//------------------------------
if (dv.TMBeginn.ToString().Substring(0, 19) == "XTGEDKDirektTelefonB" ||
@@ -717,7 +715,7 @@ namespace OnDocOffice
//word.ScreenUpdating = true;
Logging.Logging.Debug("Word Befüllen Ende", "clsOffice", dokumentid);
if (docdata.Barcode == true) { Generate_Barcodes(ref docdata); }
if (docdata.Barcode == true) { Generate_Barcodes(ref docdata, tempdir); }
Logging.Logging.Debug("Barcodes", "clsOffice", dokumentid);
if (is_protected)
@@ -728,7 +726,7 @@ namespace OnDocOffice
}
catch { }
}
//word.Visible = true;
word.Visible = true;
Logging.Logging.Debug("Start Macros", "clsOffice", dokumentid);
run_macros(ref docdata, connectionstring);
@@ -742,6 +740,7 @@ namespace OnDocOffice
Thread.Sleep(OfficeSleep);
string b64 = fh.Base64FromFile(filename);
word.Documents.Open(filename);
word.Activate();
Logging.Logging.Debug("Word geöffnet", "clsOffice", dokumentid);
worddoc = null;
word = null;
@@ -896,11 +895,11 @@ namespace OnDocOffice
g.Dispose();
return (System.Drawing.Image)b;
}
private void Generate_Barcodes(ref clsDocData docdata)
private void Generate_Barcodes(ref clsDocData docdata, string tempdir)
{
Logging.Logging.Debug("Barcode genererien start","OnDoc clsOffice",dokumentid);
vbBarcodes.vbarcodes vbcode = new vbBarcodes.vbarcodes();
vbcode.GenerateBarcodes(ref word, ref docdata, connectstring);
vbcode.GenerateBarcodes(ref word, ref docdata, connectstring,tempdir);
vbcode = null;
Logging.Logging.Debug("Barcode genererien Ende", "OnDoc clsOffice", dokumentid);
return;