Hah! That's the function I was looking for :-D Thank you Benoît!!!!!!
/Oliver Etchebarne Bejarano/ Gerente General *Paperclip X10 SRL* ================================================ Web :http://x10.pe <http://x10.pe/> Feed RSS :http://x10.pe/feed Facebook :http://x10.pe/facebook Twitter :http://x10.pe/twitter YouTube :http://x10.pe/youtube ================================================ El 18/09/11 07:47, Benoît Minisini escribió: >> Hi everyone >> >> I'm doing a little webserver in Gambas. Everything is ok so far, but I'm >> having a hard time dealing with binary files (like images). Is there a >> way to read a file in a raw fashion? >> >> I've tried to do an OPEN file FOR READ, and using a "byte" variable as >> buffer. But the bytes are read in this orden: 1, 0, 3, 2, 5, 4, 7, 6, >> etc... I think it's something about the endiannes. >> >> Again, there is a way to read a file without any format constraints? >> Thank you!!!! > If you want to serve some image files, you don't have to read it byte by byte. > You just have to open it and sent it where it is needed. > > Print #DestinationFileOrSocket, File.Load(PathToBinaryFileOnTheServer); > > Do not forget the ";", otherwise a newline will be added! > ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense. http://p.sf.net/sfu/splunk-d2dcopy1 _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user