Euphoria Libraries FAQ



1 General Library Questions

1:1 How do I find a module or application to perform task X?
Search the code archive.

1:2 How do I make a Euphoria script executable on Unix?
A: Answer me.

1:3 Is there a curses/termcap package for Euphoria?
A: Answer me.

1:4 Is there an equivalent to C's onexit() in Euphoria?
A: Answer me.

2 Common tasks

2:1 How do I test a Euphoria program or component?
A: Answer me.

2:2 How do I create documentation from doc strings?
A: Answer me.

2:3 How do I get a single keypress at a time?
A: Answer me.

3 Threads

3:1 How do I program using threads?
At the moment, Euphoria doesn't support threads.

4 Input and Output

4:1 How do I delete a file? (And other file questions...)
A: Answer me.

4:2 How do I copy a file?
A: Answer me.

4:3 How do I read (or write) binary data?
Use the "b" modifier when opening a file. Open for read by calling open("somefile","rb"), for write by calling open("somefile","wb"), for r/w by calling open("somefile","ub"), and to write in append mode by calling open("somefile","ab"). Without the 'b', the file will be seen as a text file, where some control characters have a special meaning.

To get data from the file, use get_bytes(handle,howmanybytes). To write data, use puts(handle,sequenceofbytes).

4:4 How do I access the serial (RS232) port?
A: Answer me.

5 Network/Internet Programming

5:1 What WWW tools are there for Euphoria?
Look in the Euphoria archive for internet, HTML, and CGI libraries.

5:2 How can I mimic CGI form submission (METHOD=POST)?
See Ronald Weidner's article.

5:3 What module should I use to help with generating HTML?
A: Answer me.

5:4 How do I send mail from a Euphoria script?
A: Answer me.

6 Databases

6:1 What is the Euphoria Database System?
A: Answer me.

6:2 Are there any interfaces to database packages in Euphoria?
You betcha! Click here to get a list of libraries in the Euphoria archive that help you interface to databases. These include libraries for using SQL, MySQL, Tsunami Record Manager, ODBC, SQLite, and Euphoria's own EDB format.