Cheers
Fred
Â
Hi Fred,
luckily no expert is needed :-)
Harbour does not know your VARNAME, look at:
http://x-hacker.org/ng/53guide/ngacf16.html
A line starting with a 'VALID' condition, without a ';' at line-end before, also won't work.
Your example will end up with: function VALID() not found ..
BTW, 'WHEN' and 'VALID' are no functions, but options to the 'GET' command -- and ok, you can write it like you did.
---
in my words:
Harbour 'compile', better to say 'transpile', your prg code to C-code functions with p-code.
This step includes pre-processing before ( add '-p' to see the .ppo files )
Then a C-compiler is called to generate '.o' object files.
At end, all your 'obj' files, together with the Harbour core ( the virtual machine for the p-code, terminal window, ... )
and perhaps 3rd party libs are linked to an executable file.
All these steps are done by this fantastic 'make' tool hbmk2,
which auto-locate all needed files and knows the switches for the auto-detected C-compiler/ linker.
----
As long as Harbour v3 works for you, you sure can take that version.
But v3.2 (so called 'nightly') contains 3 more years of strong development -- my advice ...
If you need Harbour 3.2 for another platform as Win32, you have to compile Harbour from source -- how to do is described in the README.md.
This is overall a good experience/ source of information to look into Harbour itself, and the overwhelming advantage of open source ...
best regards
Rolf
Â
Hi Fred,
NO bug at Harbour side ...
If i put your example lines into a 'fred.prg' with a procedure main(),
then execute: harbour fred.prg -p
=>
fred.prg(14) Error E0030 Syntax error "syntax error at '@'"
...
---
Never have seen a 'VARNAME' statement for the 'GET' command in the last decades.
Only a guess:
can it be, that you used for your Clipper pre-processer directives ?? ( http://x-hacker.org/ng/53guide/ng11fd89.html )
And on that way a non-standard Clipper 'GET' command is pre-processed ?
best regards
Rolf
Hi again,
last time i showed doc for Clipper 5.3,
here a shorter and much older 'GET' doc for summer 87:
http://www.x-hacker.org/ng/sum87/ng30f1c.html
NO 'VARNAME' !
---
BTW, can you describe what that VARNAME does ??
Is that used for the 'SAY' part ?
I would suggest to rewrite that lines to get something standard Clipper conform.
Ok, with #translate or #xtranslate we theretically can fiddle at these lines without changing, but i strong dislike such ..
best regards
Rolf
And again the question, why is HARBOUR.EXE accepting this kind of code and HBMK2 is not :-(
and one more try to explain:
hbmk2 does NOT COMPILE NOTHING, only execute e.g. Harbour.
Reconsider what a make tool is ...
And if i 'compile' your example 'directly' with harbour[.exe v3.2]:
=> i get ERRORS.
Which must be the same at you, if a hbmk2 v3 executes a harbour 3.0.
Because you report the same errors.
Which are caused by that 'VARNAME' ...
---
I still do not understand, for what this all should be.
Either you READ the variable: RA_TABLE[ LN_X, 1 ]
OR you read a variable: "AGE"
Nothing between ... :-)
best regards
Rolf
Hi Klas,
maybe i lastly found what Fred want to do,
look for the second param of _GET_():
#command @ <row>, <col> GET <var> Â Â Â Â Â Â Â Â Â Â Â Â Â Â ;
             [PICTURE <pic>]            ;
             [VALID <valid>]            ;
             [WHEN <when>]             ;
             [SEND <msg>]              ;
                                ;
  => SetPos( <row>, <col> )                  ;
   ; AAdd(                          ;
   GetList,                         ;
   _GET_( <var>, <"var">, <pic>, <{valid}>, <{when}> ):display();
      )                          ;
    [; ATail(GetList):<msg>]
best regards
Rolf