
  Doumentation for........: JobServerV3
  #New...................: 2.0411 11.12.2008;J.Fes
  #LUP...................: 3.1287;24.11.2016;J.Fes
  #LUP...................: 3.1400;14.04.2017;J.Fes any Passwords removed; TCExx removed
  #LUP...................: 3.1502;26.08.2020;J.Fes add #JobRule.ProcStateCol+1# #JobRule.ProcStateCol-1#
  #LUP...................: 3.1601;10.12.2021;J.Fes add #DateTime..#

  Content:
  List of '#' variables that can be used to replace #variables# in scripts like '.cmd' '.sql' '.txt'
  Note: the upper - lower case must be respected

  '-- Job Control ------------------------------------------------------------------------------------------------------
  #JobName#                            = JobName
  #JobParameter#                       = JobParameter
  #JobScriptParametersExtended#        = erweiterte JobScript Parameter um z.B.
                                         set JobMgr_Debug=ON
                                         set UGII_LOAD_OPTIONS_NE=load_options_refile_load_ALL_comp.def
                                         set UGII_LOAD_OPTIONS_NE=load_options_refile_load_NO_comp.def
  #TcSiteId#                           = TcSiteId
  										                             set TcSiteId=#TcSiteId#
  #TcUser#                             = TcUser
  #TcPwFile_NE#                        = TcPwFile Name and extension of password file

  #JobPacket_NE#                       = JobPacket_NE
  #JobObjectsPacket_NE#                = JobObjectsPacket_NE
  #JobObjectsPacketAllDetails_NE#      = JobObjectsPacketAllDetails_NE


  #ProcStateCol#                       = JobDef.JobRule.ProcStateCol
  #JobRule.JobName#                    = JobDef.JobControlRule.JobName
                                         #New:18.11.2020/J.Fes returns for used JobRule J.JobName
										 #Exa: J.JobName='CB1_ExtrP1_JobSizeD' -> #JobRule.JobName#='CB1_ExtrP1_JobSizeD'

  #JobRule.ProcessDataPState#          = Me.JobDef.JobControlRule.ProcessDataPState
                                         #New:18.11.2020/J.Fes returns Object PStatus when Object is send to Process
										 #Exa: J.JobName='CB1_ExtrP1_JobSizeD' -> #JobRule.ProcessDataPState#='P.CB1_ExtrP1_JobSizeD'
										 #UseCase: For extendet JobObjectSelection.sql scripts

  #JobRule.ProcStateCol#               = JobDef.JobRule.ProcStateCol
                                         #New:26.08.2020/J.Fes
  #JobRule.ProcStateCol+1#             = ProcStateCol current + 1 Example current = ProcStateCol10 then #JobRule.ProcStateCol+1# = ProcStateCol10
  #JobRule.ProcStateCol-1#             = ProcStateCol current - 1 Example current = ProcStateCol10 then #JobRule.ProcStateCol-1# = ProcStateCol09

  #JobRule.SelObjectsBy_ProcStateVal#  = JobDef.JobRule.SelObjectsBy_ProcStateVal
  #ProcStateVal#                       = JobDef.JobRule.SelObjectsBy_ProcStateVal

  #JobRule.ProcStateColDisplayText#    = JobDef.JobRule.ProcStateColDisplayText
  #JobRule.JobScriptName#              = JobDef.JobRule.JobScriptName

  '---- #New 22.04.2014
  #TcSQL_JC_DP#                        = 02-BinClient.Custom\_CustomTcSQL\#TcSiteId# 
  #TcSQL_DP#                           = 02-BinClient.Custom\_CustomTcSQL\#TcSiteId# 
  #TcSQL_JS_DP#                        = 01-BinServer.Custom\_CustomTcSQL\#TcSiteId#


  '---- 'LUp: 29.03.2013 --
  #JobDef.JobPacket_ObjectCount#       = .JobDef.JobPacket_ObjectCount
  #JobObjectsN#                        = .JobDef.JobPacket_ObjectCount

  #JobDef.JobControlRule.JobPacket_JobSumObjectCount#
                                       = .JobDef.JobControlRule.JobPacket_JobSumObjectCount
  #JobObjectApSumMax#                  = .JobDef.JobControlRule.JobPacket_JobSumObjectCount

  #JobRule.SelObjectsBy_Group#         = JobDef.JobRule.SelObjectsBy_Group
  #JobRule.SelObjectsBy_MaxApLevels#   = JobDef.JobRule.SelObjectsBy_MaxApLevels
  #JobRule.SelObjectsBy_MaxComponents# = JobDef.JobRule.SelObjectsBy_MaxComponents

  #JobRule.SelObjectsBy_MinApLevels#   = JobDef.JobRule.SelObjectsBy_MinApLevels
  #JobRule.SelObjectsBy_MinComponents# = JobDef.JobRule.SelObjectsBy_MinComponents

  #JobRule.SelObjectsBy_MultiSiteObjects#
                                       = JobDef.JobRule.SelObjectsBy_MultiSiteObjects
  #JobRule.SelObjectsBy_Name#          = JobDef.JobRule.SelObjectsBy_Name
  #JobRule.SelObjectsBy_ObjectLastModDateAfter#
                                       = JobDef.JobRule.SelObjectsBy_ObjectLastModDateAfter
  #JobRule.SelObjectsBy_ObjectLastModDateBefor#
                                       = JobDef.JobRule.SelObjectsBy_ObjectLastModDateBefor

  #JobRule.SelObjectsBy_ObjectType#    = JobDef.JobRule.SelObjectsBy_ObjectType
  #ObjectType#                         = JobDef.JobRule.SelObjectsBy_ObjectType

  #JobRule.SelObjectsBy_Owner#         = JobDef.JobRule.SelObjectsBy_Owner
  #JobRule.SelObjectsBy_PFM#           = JobDef.JobRule.SelObjectsBy_PFM
  #JobRule.SelObjectsBy_ProcStateJobControlButton_N_or_M#
                                       = JobDef.JobRule.SelObjectsBy_ProcStateJobControlButton_N_or_M

									     #New: 15.01.2019/J.Fes
  #JobRule.SelObjectsBy_Status#        = Me.JobDef.JobControlRule.SelObjectsBy_Status  

  #JobRule.SelObjectsBy_SQLScript_PPNE#= JobDef.JobRule.SelObjectsBy_SQLScript_PPNE
  #JobRule.SelObjectsBy_SQLScript_YN#  = JobDef.JobRule.SelObjectsBy_SQLScript_YN
  #JobRule.SelObjectsBy_UgMasterType#  = JobDef.JobRule.SelObjectsBy_UgMasterType
  #JobRule.SelObjectsBy_Volume#        = JobDef.JobRule.SelObjectsBy_Volume
  #JobRule.TimeSchedule#               = JobDef.JobRule.TimeSchedule
  #JobRule.validForComputer#           = JobDef.JobRule.validForComputer

  #JobRule.SelObjectsBy_ObjectClass#   = JobDef.JobRule.SelObjectsBy_ObjectClass_Enum_AsString
  #JobRule.SelObjectsBy_ObjectSpecSelRule# = JobDef.JobRule.SelObjectsBy_ObjectSpecSelRule_Enum_AsString
  #ObjectClass#                        = JobDef.JobRule.SelObjectsBy_ObjectClass_Enum_AsString


  '-- #New: 25.06.2009 - - - -
  #JobScriptTemplate_DP#        : Verz. in dem das JobScript auf dem Server liegt [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox\ClientScripts]
  #JobScriptTemplateMinus1_DP#  : 1 Verz. tiefer als #JobScriptTemplate_DP#       [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox]
  #JobScriptTemplate_DPNE#      : Quelle der Scriptvorlage                        [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox\ClientScripts\NXCheckBox.Cmd]
  '-- #New: 05.04.2011 - - - -
  #JobScript_DP#                : Verz. in dem das JobScript auf dem Server liegt [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox\ClientScripts]
  #JobScriptMinus1_DP#          : 1 Verz. tiefer als #JobScriptTemplate_DP#       [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox]
  #JobScript_DPNE#              : Quelle der Scriptvorlage                        [Example: ..\JobManagerV3\90-DATA\Custom_SettingsGlobal\10-JobScripts\NXCheckBox\ClientScripts\NXCheckBox.Cmd]


  '-- Site Info of JobData ---------------------------------------------------------------------------------------------
  #TcSite.Id#                                             .JobDef.Site_cls_Using.Id
  #TcSite.DBNetworkAlias#                                 .JobDef.Site_cls_Using.DBNetworkAlias
  #TcSite.DBProvider#                                     .JobDef.Site_cls_Using.DBProvider
  #TcSite.OracleBin#                                      .JobDef.Site_cls_Using.OracleBin
  #TcSite.OracleHome#                                     .JobDef.Site_cls_Using.OracleHome
  #TcSite.pName#                                          .JobDef.Site_cls_Using.pName
  #TcSite.Tns_Admin#                                      .JobDef.Site_cls_Using.Tns_Admin
  #TcSite.UserName#                                       .JobDef.Site_cls_Using.UserName
  #TcSite.UserPW#                                         .JobDef.Site_cls_Using.Password
  #TcSite.SiteAktive_bol#                                 .JobDef.Site_cls_Using.SiteAktive_bol.ToString
  #TcSite.pSite_ID#                                       .JobDef.Site_cls_Using.pSite_ID
  #TcSite.pName#                                          .JobDef.Site_cls_Using.pName
  #TcSite.ImportItemLastModifyDateBegin#                  .JobDef.Site_cls_Using.ImportItemLastModifyDateBegin.ToString
  #TcSite.ImportItemLastModifyDateEnd#                    .JobDef.Site_cls_Using.ImportItemLastModifyDateEnd.ToString

  #TcSite.NativeRoot_DP#                                  .JobDef.Site_cls_Using.NativeRoot_DP
  #TcSite.NativeMaskAp#                                   .JobDef.Site_cls_Using.NativeMaskAp
  #TcSite.NativeFileSysUsing_bol#                         .JobDef.Site_cls_Using.NativeFileSysUsing_bol.ToString
  #TcSite.NativeFileMaskExclude#                          .JobDef.Site_cls_Using.NativeFileMaskExclude
  #TcSite.NativeFileMaskInclude#                          .JobDef.Site_cls_Using.NativeFileMaskInclude
  #TcSite.SiteInfoWith_SiteId_and_pName#                  .JobDef.Site_cls_Using.SiteInfoWith_SiteId_and_pName


  '-- JobServer Setting ------------------------------------------------------------------------------------------------
  #TcpPeerAddr#                                           .JobServer_TcpPeerAddr
  #JobServerComputerName#                                 .JobServer_ComputerName
  #TcpPeerPort#                                           .JobServer_TcpPeerPort
  #JobClientWaitTimeForNextServerConnection#              .JobServer_JobClientWaitTimeForNextServerConnection
  #FileTrans_1MBTimeOut#                                  .JobServer_TcpServerFileTrans_1MBTimeOut
  #TcpServer_BaseComTimeOut#                              .JobServer_TcpServer_BaseComTimeOut


  '-- JobServer Base Directory  ----------------------------------------------------------------------------------------
  #MyApplName_TP#                                         MyApplBase_TP
  #DataRoot_CustomWorkInst_DP#                            .Dir_DataRoot_DP_CustomWorkInst

  #00-ApplRoot_DP#                                        .Dir_RootUsed_DP
  #01-BinServer_DP#                                       .Dir_01_BinServer_DP
  #02-BinClient_DP#                                       .Dir_02_BinClient_DP
  #03-BinPublic_DP#                                       .Dir_03_BinPublic_DP               
  
  New: 2.962;20.02.2012;J.Fes
  #03_BinPublic_ClientServer_DP#                          set BinPublic_ClientServer_DP=#03_BinPublic_ClientServer_DP#
  #03-BinPublic_Custom_DP#                                set BinPublic_Custom_DP=#03-BinPublic_Custom_DP#
  
  #10-JobLogArchiv#                                       .Dir_DataRoot_DP_10JobLogArchiv
  #11-ServerSysLog#                                       .Dir_DataRoot_DP_11ServerSysLog
  #12-Data#                                               .Dir_DataRoot_DP_12Data.ToString

  #11-Doku_DP#                                            .Dir_11_DocumentationCustom_DP
  #90-Data_DP#                                            .Dir_DataRoot_DP_DATA

  #DataRoot_CustomWorkInst_DP#                            .Dir_DataRoot_DP_CustomWorkInst
  #New: 3.1503;15.03.2021;S.Gueth
  #Dir_DataRoot_DP_91JobControl#                          .Dir_DataRoot_DP_91JobControl

  #20-JobComputerScripts_DP#                              .Dir_DataRoot_DP_Customer_SettingsGlobal_20JobComputerScripts
  #20-JobComputerScripts_Template_DP#                     .Dir_DataRoot_DP_Customer_SettingsGlobal_20JobComputerScripts_Template
  #30-TSQLComputerScripts_DP#                             .Dir_DataRoot_DP_Customer_SettingsGlobal_30TSQLScripts

  #10-JobScripts_DP#                                      .Dir_DataRoot_DP_Customer_SettingsGlobal_10JobScripts 
                                                            |-> [Example: ..\JobManagerV3\90-DATA\CustomerNameShort_SettingsGlobal\10-JobScripts]
  

  #New: 3.1286;24.11.2016;J.Fes
  #40-JobServerScripts_DP#                                .Dir_40_JobServerScriptsCustomer_DP -> Location for JobServer.net Scripts
                                                            |-> [Example: ..\JobManagerV3\90-DATA\CustomerNameShort_SettingsGlobal\40-JobServerScripts]
  #40-JobServerScriptsL_DP#                               .Dir_40_JobServerScriptsCustomer_DP -> Location for JobServer.net Local on JobServer 

  #New: 2.987;05.04.2012;J.Fes;This can be used to refer to the JobLogZipArchive file in an e-mail
  #JobLogZipArchiv_DPNE#                                  set JobLogZipArchiv_DPNE=#JobLogZipArchiv_DPNE#


  '-- Details of the JobComputer Client --------------------------------------------------------------------------------
  #JobComputers_tbl.ComputerName#                         .ComputerName
  #JobComputers_tbl.ComputerFQDN#                         .ComputerFQDN (new 09.07.2010)
  #JobComputers_tbl.ComputerAktiv#                        .ComputerAktiv
  #JobComputers_tbl.TcUser#                               .TcUser


  #JobComputers_tbl.TimeSchedule#                         .TimeSchedule
  #JobComputers_tbl.LastConnectionDateTimeLocal#          .LastConnectionDateTimeLocal
  #JobComputers_tbl.LastConnectionDateTimeGMT#            .LastConnectionDateTimeGMT

  #JobComputers_tbl.Memory#                               .Memory
  #JobComputers_tbl.CpuMhz#                               .CpuMhz
  #JobComputers_tbl.Os#                                   .OS

  #JobComputers_tbl.ComputerDescription#                  .ComputerDescription
  #JobComputers_tbl.ComputerAssignment#                   .ComputerAssignment

  #JobComputers_tbl.NxVersion#                            .NxVersion
  #JobComputers_tbl.TcVersion#                            .TcVersion

  #JobComputers_tbl.Place#                                .Place
  #JobComputers_tbl.Notice#                               .Notice
  #JobComputers_tbl.IP#                                   .IP

  #JobComputers_tbl.Custom01#                             .Custom01  (new 09.07.2010)
  #JobComputers_tbl.Custom02#                             .Custom02  (new 09.07.2010)
  #JobComputers_tbl.Custom03#                             .Custom03  (new 09.07.2010)
  #JobComputers_tbl.Custom04#                             .Custom04  (new 09.07.2010)


  '-- Details of the JobServer Software  -------------------------------------------------------------------------------
  #MyApplVer#                                             MyApplVer
  #MyApplBase_TP#                                         MyApplBase_TP
  #MyApplTitle#                                           MyApplTitle
  #MyApplTitleShort#                                      MyApplTitleShort


  '-- Details of the JobServer SQL Server   ----------------------------------------------------------------------------
  ' SQL Server -> siehe auch TSQL Scripts
  #DB_N#                                                  .MSSQL_DATABASE_Name
  #DB_DP#                                                 .MSSQL_DATABASE_DataMdf_DP
  #DB_mdf_NE#                                             .MSSQL_DATABASE_DataMdf_NE
  #DB_mdf_DPNE#                                           .MSSQL_DATABASE_DataMdf_DPNE
  #DB_ldf_NE#                                             .MSSQL_DATABASE_DataLdf_NE
  #DB_ldf_DPNE#                                           .MSSQL_DATABASE_DataLdf_DPNE

  '-- Details of the JobServer JobPlaner Variablen ---------------------------------------------------------------------
   rem JobPlanerValues Info alle Variablen beginen mit JobPlaner_
  #JobPlaner_Owner#                                       UserName of User generated the JobPlaner Task 
  #JobPlaner_Param#                                       Parameters selected when creating the JobPlaner task

  #JobPlaner_ProcessStepControl#                          Curretn Process Step .. UGMaster .. UGNonMaster .. Done
  #JobPlaner_TimeSchedule#                                Schedule Time [DA=28.04.2009 TP=15:40]
  #JobPlaner_Name#                                        Task Name
  #JobPlaner_Description#                                 Task Description
  #JobPlaner_NameDescription#                             Task Name + Description
  #JobPlaner_Note#                                        Note that was assigned to the task record
  #JobPlaner_Order#                                       Task order
  #JobPlaner_ProcessLastMsg#                              Aktuelle letzte Meldung
  #JobPlaner_ProcessLastRunStart#                         Task Last Run Start
  #JobPlaner_ProcessLastRunEnd#                           Task Last Run End
  #JobPlaner_ProcessObjectsProcStateCol#                  Task refers to Process Group number
  #JobPlaner_ProcessState#                                Task State N .. P .. W .. D
  #JobPlaner_ProcessStepControl#                          StepControl UGMaster .. UGNonMaster .. Done
  #JobPlaner_ProcessType#                                 JPJob=JobPlaner.Job  TaskJob=Task.Job
  #JobPlaner_ReDo#                                        is Redo Aktive ?

  '-- JobPlaner Environ Variable ---------------------------------------------------------------------------------------
  Info: all environment variables that are set when creating a JobPlanerTask can be transferred via the
  #JobPlanerEnv_EnvironmentVARNAME# into the script. Note: the environment variable must be written in capital letters!
  Example:
  #JobPlanerEnv_PATH#                                     Wert der Path Variaben die gesetzt war in der Umgebung des JobPlaners
  #JobPlanerEnv_COMPUTERNAME#                             ComputerName des Rechners auf dem der JobPlanerTask erzeugt wurde

  '-- Function Variable ------------------------------------------------------------------------------------------------
  #New: 3.1601;10.12.2021;J.Fes
  #DateNow#                                               10.12.2021
  #DateTimeNow#                                           10.12.2021 11:15
  #DateTimeNow_DDMMYYYYHMS#                               10.12.2021 11:15:20
  #DateTimeNow_ForSqlServer#                              Convert(datetime,'2021-12-10 11:15:24',120)


  '-- JobScript --------------------------------------------------------------------------------------------------------
  #New: 3.1299;08.02.2017;J.Fes
  If to JobPacket the JobData need to be add as text files
  then please add job main script: 
   - for ObjectsList..........:  
  set JobAddFile_ObjectsList_txt=true
   - for ObjectsListAllDetails:  
  set JobAddFile_ObjectsListAllDetails_txt=true

