So im really new to programming in general and when i say really new i literally know nothing and the little i now is from C an imperative language, so im all confused about object oriented fantom, the reason im here is because i have to research this language as a project for one of my subjects in university.
Now i'll head to my problem, i want the fan.exe don't close inmediately after the code ends i want it to stay so i can see the output can i do this? or am i asking nonsense?
EDIT: i wanted to add that as im a beginner i would be so grateful if you treated me like a baby, im very noob im sorry.
ahhatemTue 13 May 2014
Hi Lokem,
Welcome to Fantom.. I hope you enjoy it around here...
What you are looking for is something to stop the program from closing, usually that is:
Env.cur.in.readLine
That way it will exit when you press enter.
tomclTue 13 May 2014
Or...
Run fan under a command window (type cmd into the Windows Start Menu box). Then you will see the output.
(I assume you have put the fantom executable directory in your path - otherwise replace fan by c:\fantom\bin\fan etc)
e.g.:
cd c:\fantom\examples\sys
fan lists.fan
Env.cur.readLine will work as well because it will prevent the program terminating and its window will stay on the screen till you type return.
LokemWed 14 May 2014
Thanks for the fast answer, this helped a lot
Env.cur.in.readLine
Don't know why but i was in fact running from cmd the .fan when this closed window happened, thanks for the help guys again.
Lokem Tue 13 May 2014
So im really new to programming in general and when i say really new i literally know nothing and the little i now is from C an imperative language, so im all confused about object oriented fantom, the reason im here is because i have to research this language as a project for one of my subjects in university.
Now i'll head to my problem, i want the fan.exe don't close inmediately after the code ends i want it to stay so i can see the output can i do this? or am i asking nonsense?
EDIT: i wanted to add that as im a beginner i would be so grateful if you treated me like a baby, im very noob im sorry.
ahhatem Tue 13 May 2014
Hi Lokem,
Welcome to Fantom.. I hope you enjoy it around here...
What you are looking for is something to stop the program from closing, usually that is:
That way it will exit when you press enter.
tomcl Tue 13 May 2014
Or...
Run fan under a command window (type cmd into the Windows Start Menu box). Then you will see the output.
(I assume you have put the fantom executable directory in your path - otherwise replace fan by c:\fantom\bin\fan etc)
e.g.:
Env.cur.readLine
will work as well because it will prevent the program terminating and its window will stay on the screen till you type return.Lokem Wed 14 May 2014
Thanks for the fast answer, this helped a lot
Don't know why but i was in fact running from cmd the .fan when this closed window happened, thanks for the help guys again.