Hi! I am reading and writing from an external text file using FileStream and as long as the file is in "default" directory everything works but I am stuck in my "old" VisualWork world! In vw you use a class called Filename and there is a class method called separator to get hold of the separator for the current OS. Is there somrthing equal in squeak to be able to make my app. not depending on a specific OS?
I believe there exists FileDirectory class>>#slash and FileDirectory class>>#dot. I don't have an image right in front of me in order to check.
On 11/1/05, Marcus Pedersén marcus.pedersen@comhem.se wrote:
Hi! I am reading and writing from an external text file using FileStream and as long as the file is in "default" directory everything works but I am stuck in my "old" VisualWork world! In vw you use a class called Filename and there is a class method called separator to get hold of the separator for the current OS. Is there somrthing equal in squeak to be able to make my app. not depending on a specific OS?
-- Jason Rogers
"I am crucified with Christ: nevertheless I live; yet not I, but Christ liveth in me: and the life which I now live in the flesh I live by the faith of the Son of God, who loved me, and gave himself for me." Galatians 2:20
To complement Jason's answer, I would add: FileDirectory pathNameDelimiter
Cheers, Alexandre
On Nov 1, 2005, at 10:35 PM, Marcus Pedersén wrote:
Hi! I am reading and writing from an external text file using FileStream and as long as the file is in "default" directory everything works but I am stuck in my "old" VisualWork world! In vw you use a class called Filename and there is a class method called separator to get hold of the separator for the current OS. Is there somrthing equal in squeak to be able to make my app. not depending on a specific OS?
Or, ignore the whole platform mess and use URIs. Install via Squeakmap (http://map1.squeakfoundation.org/sm/package/ d4019d26-539f-42cb-9fe3-83058bce64e6) or Monticello (http:// kilana.unibe.ch:8888/URI.html).
- Bert -
Am 02.11.2005 um 08:25 schrieb Alexandre Bergel:
To complement Jason's answer, I would add: FileDirectory pathNameDelimiter
Cheers, Alexandre
On Nov 1, 2005, at 10:35 PM, Marcus Pedersén wrote:
Hi! I am reading and writing from an external text file using FileStream and as long as the file is in "default" directory everything works but I am stuck in my "old" VisualWork world! In vw you use a class called Filename and there is a class method called separator to get hold of the separator for the current OS. Is there somrthing equal in squeak to be able to make my app. not depending on a specific OS?
squeak-dev@lists.squeakfoundation.org