From be0914b06d2460fa63f1fd481df9014d8911c18b Mon Sep 17 00:00:00 2001 From: Roland Heyder Date: Thu, 12 Sep 2024 01:19:53 +0200 Subject: [PATCH] Export function fix - fix wrong wiki links in OPEN statements - all OPEN related KWs link to the respective sections at the OPEN wiki page - all other KWs involved in filename, filenumber or recordlength specification must link to their own wiki pages --- source/ide/ide_methods.bas | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/source/ide/ide_methods.bas b/source/ide/ide_methods.bas index 10e761f67..21b9804c3 100644 --- a/source/ide/ide_methods.bas +++ b/source/ide/ide_methods.bas @@ -21023,11 +21023,15 @@ SUB ExportCodeAs (docFormat$) IF me% THEN page$ = UCASE$(me$): ELSE page$ = UCASE$(kw$) 'Wiki pages are all caps IF op% THEN SELECT CASE page$ - CASE "ACCESS", "LOCK", "SHARED", "READ", "WRITE": page$ = "OPEN#File_ACCESS_and_LOCK_Permissions" - CASE "FOR", "OUTPUT", "APPEND", "INPUT", "BINARY", "RANDOM": page$ = "OPEN#File_Access_Modes" - CASE ELSE: page$ = "OPEN" + CASE "OPEN", "AS": page$ = "OPEN": RETURN + CASE "LEN" + la$ = LTRIM$(StrReplace$(MID$(sTxt$, sPos&, 100), CHR$(9), " ")) + IF LEFT$(la$, 1) <> "(" THEN page$ = "OPEN": RETURN + CASE "ACCESS", "LOCK", "SHARED", "READ", "WRITE": page$ = "OPEN#File_ACCESS_and_LOCK_Permissions": RETURN + CASE "FOR", "OUTPUT", "APPEND", "INPUT", "BINARY", "RANDOM": page$ = "OPEN#File_Access_Modes": RETURN END SELECT - ELSEIF (fu% < 0) AND ((INSTR(fu$, "@" + page$ + "@") > 0) OR (np% AND INSTR(fu$, "@_" + page$ + "@") > 0)) THEN + END IF + IF (fu% < 0) AND ((INSTR(fu$, "@" + page$ + "@") > 0) OR (np% AND INSTR(fu$, "@_" + page$ + "@") > 0)) THEN page$ = page$ + " (function)" ELSEIF bo% AND INSTR(bo$, "@" + page$ + "@") > 0 THEN 'np% check omitted (legacy words only) page$ = page$ + " (boolean)"