Hello

I've written a small Mac-OS-X FLTK app that writes a file using fopen(), 
fwrite(), fclose().

The call to fopen is something like fopen("test.txt", "w").

The executable is on my desktop.

When I run it, the file test.txt is written to the root directory '/' 
instead of my desktop.

What can I do to make it write the file to the same directory as the 
compiled executable?

I tried fopen("./test.txt", "w") but the file still went to the root 
directory.

I also tried fopen("~/Desktop/test.txt", "w") but that crashed the program.

I'm using fltk 1.1.7 on Mac OS X Tiger.

Thanks

PS: I also compiled this in MS Windows and it writes the file the same 
directory as the executable, as desired.

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to