realbasic-nug
[Top] [All Lists]

Re: Little Endian

To: REALbasic NUG <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Little Endian
From: Aaron Ballman <aaron at realsoftware dot com>
Date: Thu, 30 Sep 2004 17:43:04 -0500
Delivered-to: realbasic-nug at lists dot realsoftware dot com
References: <20040930 dot 173316 dot -427723 dot 0 dot Erockus at juno dot com>
In one of my projects I'm using binary stream with
WriteShort and WritePString - Read as well.
Now if someday I do a Windows build isn't there
something I need to do about the LittleEndian thing?

If you want the file to be read no matter what platform you're on, make sure to write it out and read it in with the same format every time -- explicitly set LittleEndian to the same value everywhere. I tend to use LittleEndian = false since big endian format is what's used in networking and I do a lot of networking code. But it really doesn't matter what you pick so long as you're consistent.

HTH!

~Aaron
--
REAL World 2005 - The REALbasic User Conference
March 23-25, 2005, Austin, Texas
<http://www.realsoftware.com/realworld>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://www.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>