Update 20241118
This commit is contained in:
@@ -11,6 +11,7 @@ using Model;
|
||||
using System.Diagnostics;
|
||||
using NLog;
|
||||
using System.Security.Policy;
|
||||
using OfficePrinter;
|
||||
|
||||
namespace DOCGEN.Generator
|
||||
{
|
||||
@@ -42,7 +43,7 @@ namespace DOCGEN.Generator
|
||||
this.tempdir = tempdir;
|
||||
}
|
||||
|
||||
public clsdok Generate_Doc_EDOKA(string dokumentid, ref clsDocData docdata )
|
||||
public clsdok Generate_Doc_EDOKA(string dokumentid, ref clsDocData docdata, bool useoffice = false )
|
||||
{
|
||||
DB db = new DB(connectionstring);
|
||||
DataTable dt = new DataTable();
|
||||
@@ -59,7 +60,14 @@ namespace DOCGEN.Generator
|
||||
SyncFWord sfword = new SyncFWord();
|
||||
generate_docdata(dokumentid, ref docdata);
|
||||
clsdok dok = new clsdok("", "", "");
|
||||
dok.dokument= sfword.Generate_Word(dt.Rows[0][0].ToString(), docdata);
|
||||
if (useoffice == false) {
|
||||
dok.dokument = sfword.Generate_Word(dt.Rows[0][0].ToString(), docdata);
|
||||
} else
|
||||
{
|
||||
OnDocOffice.clsWordEdit oo = new OnDocOffice.clsWordEdit("", "","");
|
||||
dok.dokument = oo.Generate_Word_in_Office(ref docdata, ref dok, dt.Rows[0][0].ToString(), connectionstring, tempdir, dokumentid, Apptype);
|
||||
}
|
||||
|
||||
dok.doktype = "D";
|
||||
dok.extension = dt2.Rows[0][1].ToString();
|
||||
//if (dok.extension.ToUpper()=="DOTM") { dok.extension = "docm"; }
|
||||
|
||||
Reference in New Issue
Block a user