🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.next.programmer
Article #1590

Writing data from a Window to a file (I/O under NeXTStep)...Help!

#1590
From: Leif E. Harrison
Date: Fri, 13 Nov 1992 04:37
29 lines
1848 bytes
     How does one go about taking data that has been entered in a group
 of objects in a window (say, 4 Forms, 1 Button, and 1 ScrollView) and
 saving them out to a file?

     My current almost-working solution is to use NXWriteRootObject() and
 a write method in a custom object that basically just does a [myWindow
 write:myStream].  Using this method, however, I can't seem to get it to
 use the correct filename...it uses the class name instead...?

     Would it be better to keep the data from the window in some sort of
 structure and using NXWriteType()?

     I s'pose listing my code might help, but my system isn't anywhere
 *near* a network, so I'd have to transcribe it by hand...
     Perhaps tomorrow I'll try that...

     Oh!  And how the heck do you refer to individual Forms/FormCells
 within a Window? I can't seem to understand how to get the id's of these
 objects...I tried putting some id instance variables in my class, but I'm
 not sure how it might "automagically" attach the forms to the id's in
 my class (the Window id seems to do this?).  This may be connected to
 my filename problem, as I'm using the StringValue from one of the Forms
 as my filename...or at least trying to...

     Help?!?

	- Leif Harrison
	  n9240566@henson.cc.wwu.edu
Technical Details
Message-ID: <1992Nov13.043739.13179@henson.cc.wwu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!know!hri.com!noc.near.net!news.Brown.EDU!qt.cs.utexas.edu!cs.utexas.edu!swrinde!emory!ogicse!reed!henson!n9240566

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!know!hri.com!noc.near.net!news.Brown.EDU!qt.cs.utexas.edu!cs.utexas.edu!swrinde!emory!ogicse!reed!henson!n9240566
From: n9240566@henson.cc.wwu.edu (Leif E. Harrison)
Newsgroups: comp.sys.next.programmer
Subject: Writing data from a Window to a file (I/O under NeXTStep)...Help!
Summary: Need help taking data from a Window and saving to a file
Keywords: I/O, NeXTStep, Help,
Message-ID: <1992Nov13.043739.13179@henson.cc.wwu.edu>
Date: 13 Nov 92 04:37:39 GMT
Organization: Western Washington University
Lines: 29