gettingstarted
[Top] [All Lists]

RE: (no subject)

To: "'Getting Started'" <gettingstarted at lists dot realsoftware dot com>
Subject: RE: (no subject)
From: "RBNUBE" <rbnube at mabenterprises dot com>
Date: Sat, 31 Jul 2004 22:27:17 -0500
Delivered-to: gettingstarted at lists dot realsoftware dot com
Importance: Normal
Keywords: rb-gettingstarted
Not sure if I understand, but it sounds like you just want to collect
text from several editfields and save this text to a text file.  If so,
couldn't you do this...

Dim theText as string

theText = editfield1.text + endofline + endofline + editfield2.text +
endofline + endofline + editfield3.text (etc.)

Then write theText to a file.



-----Original Message-----
From: gettingstarted-bounces at lists dot realsoftware dot com
[mailto:gettingstarted-bounces at lists dot realsoftware dot com] On Behalf Of 
Greg
Olson-Hyde
Sent: Saturday, July 31, 2004 7:49 PM
To: Getting Started
Subject: (no subject)


G'day all

Terry requested another question, so here it is  :-)

I have an EditField that I am saving to, and loading from, a text file. 
I have the ability to save and load 'multi lines' with carriage 
returns.

So far so good, all is functioning, but...

I want to save and load 'multi lines' using more than one EditField. I 
can see how to save many 'single line' strings to one file but how can 
I save many 'multi line' strings with one or many carriage returns from 
many EditFileds to the same text file. I will use a database if 
required but as there will only ever be one record this may be 
overkill. Does this make sense?

The code I am using to load multi line text into one EditField is below:

   Dim f As folderItem
   Dim t As textInputStream
   f = preferencesFolder.child("Notes")
   if f <> nil then
     if f.exists then
       t = f.OpenAsTextFile
       if t <> nil then
         psNotesText = t.readAll
         efMyNotes.Text = psNotesText
         t.close
       end if
     end if
   end if

RB 5.5.2, Mac OS X 10.3.4
Cheers

Greg
Sydney Australia

_______________________________________________
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>

_______________________________________________
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>