Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
inti2: conditional #compile "..." (named constant)
#1
In my init2 I want to do (A and B = QM function with named constants defined).
 
Code:
Copy      Help
if(FileExists(path 1)
    #compile "A"
else
    #compile "B"

Is there a way to do this?
I tried with goto, but it still attempts to process bot A and B

With goto I mean:

if(FileExists(path 1)
    goto skip A  ;; This would then skip over #compile "A"

But this does not work.

EDIT:
forgot to mention, I tried to put A and B in seperate functions, meaning create 2 functions and put only the #compile... line in those functions.
Then call the functions from init2 using if statements, but I still conflict error:
...:  previous declaration is different.  Restart QM or reopen file.


Messages In This Thread
inti2: conditional #compile "..." (named constant) - by r0n - 07-21-2021, 01:58 PM

Forum Jump:


Users browsing this thread: 2 Guest(s)