Hey Richard, I'm using Gambas2 version 2.14 on a Debian Lenny distro and I just tested your code with a minor change.
Print #wfile stext should be changed to Print #wfile, stext Other than that minor change everything works fine. I hope this helps Regards, Dimitris On Sat, Jul 25, 2009 at 2:30 AM, richard terry <[email protected]>wrote: > this bombs in the latest gambas with syntax error and with my dyslexia and > inablity to interpret the Doc's I can't figure it out, so I wondered if > some > kind soul could enlighten me, as it always worked prior to 2136 build and > Benoit alluded to the fact that he's since fixed a compiler error (which > must > have let the syntax error through). > > Thanks. > > Richard > > > Public Sub Print_To_File(stext As String, filename As String) > '------------------------------------------------------------ > 'Saves a string to a file without the byte count at the top > 'Note the file is created if does not exist, or cleared first > 'if it does exist > '------------------------------------------------------------ > Dim wFile As File > Open Filename For Write Create As #wfile > Print #wfile stext ****BOMBS ON THIS LINE!!!! > Close #wfile > End > > > ------------------------------------------------------------------------------ > _______________________________________________ > Gambas-user mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/gambas-user > ------------------------------------------------------------------------------ _______________________________________________ Gambas-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/gambas-user
