From 4a069c6e47c6923d969fa217a026f3ee75ce5b8f Mon Sep 17 00:00:00 2001 From: Patrick Date: Thu, 19 May 2022 11:17:45 +0200 Subject: [PATCH] Failed to start in v10 --- DataDigger.i | 2 +- DataDigger.txt | 3 ++- DataDigger2.p | 3 +++ DataDiggerLib.p | 10 ++++++++++ dCloneDatabase.w | 11 ++++++++--- 5 files changed, 24 insertions(+), 5 deletions(-) diff --git a/DataDigger.i b/DataDigger.i index d8dbd9e..bfeb04d 100644 --- a/DataDigger.i +++ b/DataDigger.i @@ -11,7 +11,7 @@ /*----------------------------------------------------------------------*/ &GLOBAL-DEFINE version {version.i} -&GLOBAL-DEFINE edition Rudolf +&GLOBAL-DEFINE edition Ironman &GLOBAL-DEFINE build {build.i} &GLOBAL-DEFINE QUERYSEP CHR(2, SESSION:CPINTERNAL, "UTF-8") diff --git a/DataDigger.txt b/DataDigger.txt index 5616b89..d3f6776 100644 --- a/DataDigger.txt +++ b/DataDigger.txt @@ -6,7 +6,7 @@ ===================================================================================== -DataDigger version 26 +DataDigger version 26 - 19 may 2022 (Iron Man) - New : Option for abbreviated datatypes in generate temp-table include (Baltazar Oliveira) - New : Option for abbreviated datatypes in generate active record class @@ -27,6 +27,7 @@ DataDigger version 26 - Solved: Cannot type umlaut in filter row #83 (movedoa) - Solved: Inactivated index shows as active #75 - Solved: Active index shown as inactive #86 (Richard Kelters) +- Solved: Failed to start in v10 - Changed: Starting the libraries is simplified, contact me when you have errors - Changed: When dumping to Excel, assume codepage 1252 when current is ISO8859 diff --git a/DataDigger2.p b/DataDigger2.p index 39d16bb..6920080 100644 --- a/DataDigger2.p +++ b/DataDigger2.p @@ -591,7 +591,10 @@ PROCEDURE recompileSelf : PUT UNFORMATTED SKIP(0) " Windows version : " SESSION:WINDOW-SYSTEM " " cSystem + ", " getProcessorArchitecture() "bit". PUT UNFORMATTED SKIP(0) " System memory : " cMemory. PUT UNFORMATTED SKIP(0) " Display size : " SESSION:WORK-AREA-WIDTH-PIXELS " x " SESSION:WORK-AREA-HEIGHT-PIXELS. + + &IF PROVERSION >= "11" &THEN PUT UNFORMATTED SKIP(0) " Logged in as : " System.Environment:GetEnvironmentVariable("username"). + &ENDIF PUT UNFORMATTED SKIP(1) "SESSION INFO". PUT UNFORMATTED SKIP(0) " Program dir : " gcProgramDir. diff --git a/DataDiggerLib.p b/DataDiggerLib.p index 464fb51..37c8039 100644 --- a/DataDiggerLib.p +++ b/DataDiggerLib.p @@ -5056,9 +5056,19 @@ FUNCTION resolveOsVars RETURNS CHARACTER DEFINE VARIABLE i AS INTEGER NO-UNDO. DO i = 1 TO NUM-ENTRIES(pcString,'%'): + + &IF PROVERSION < "11" &THEN + /* Old style for v10 */ + IF i MODULO 2 = 0 + AND OS-GETENV(ENTRY(i,pcString,'%')) <> ? THEN + ENTRY(i,pcString,'%') = OS-GETENV(ENTRY(i,pcString,'%')). + + &ELSE + IF i MODULO 2 = 0 AND System.Environment:GetEnvironmentVariable(ENTRY(i,pcString,'%')) <> ? THEN ENTRY(i,pcString,'%') = System.Environment:GetEnvironmentVariable(ENTRY(i,pcString,'%')). + &ENDIF END. pcString = REPLACE(pcString,'%',''). diff --git a/dCloneDatabase.w b/dCloneDatabase.w index d5fec2c..6d88af0 100644 --- a/dCloneDatabase.w +++ b/dCloneDatabase.w @@ -275,10 +275,15 @@ PROCEDURE cloneDatabase : RETURN. END. - cDlc = System.Environment:GetEnvironmentVariable('DLC':U). + &IF PROVERSION < "11" &THEN + cDlc = OS-GETENV('DLC'). + &ELSE + cDlc = System.Environment:GetEnvironmentVariable('DLC'). + &ENDIF + IF cDlc = ? THEN - ASSIGN cDlc = SEARCH('empty.db':U) - cDlc = SUBSTRING(cDlc,1,LENGTH(cDlc,'CHARACTER':U) - 9,'CHARACTER':U). + ASSIGN cDlc = SEARCH('empty.db') + cDlc = SUBSTRING(cDlc,1,LENGTH(cDlc,'CHARACTER') - 9,'CHARACTER'). /* Point to the proper database */ CREATE ALIAS 'dictdb' FOR DATABASE VALUE(pcDbName).