🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.pascal.borland
Article #689

Re: Writing to text Files

#689
From: Sebastian Schleussner
Date: Wed, 09 Jun 1999 00:00
18 lines
1374 bytes
wob82 wrote:
> is everything clear right now??
Not quite...

Firstly, you declared a variable with a name that is a reserved word in
Pascal, namely "file".  Although that is possible to do somehow, it is
HIGHLY critical. DON'T do it!  Try something like outfile instead.
Secondly, you can't use "reset" to open a file for writing, not even if
the file is already existing. You must use "append" instead!
Thirdly, you use two vars, "c" and "x" in the main prog, which you
didn't declare before. You would get an error from your compiler for
that! Maybe you meant "c" to be "s", which you did declare, but not use;
then, however, you must say 
	c := 'x';
if anything.

Hope that helps.
Sebastian
Technical Details
Message-ID: <375E77E6.F5D23B5E@gmx.de>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <7jaola$r31$1@news5.svr.pol.co.uk> <7jhbvk$7cj$1@news.online.de>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 110467,863a3507bf12c2da
X-Google-Attributes: gid110467,public
X-Google-Thread: 111659,863a3507bf12c2da
X-Google-Attributes: gid111659,public
From: Sebastian Schleussner <Sebastian.Schleussner@gmx.de>
Subject: Re: Writing to text Files
Date: 1999/06/09
Message-ID: <375E77E6.F5D23B5E@gmx.de>
X-Deja-AN: 487506097
Content-Transfer-Encoding: 7bit
References: <7jaola$r31$1@news5.svr.pol.co.uk> <7jhbvk$7cj$1@news.online.de>
Organization: Comp.Center (RUS), U of Stuttgart, FRG
Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0
Newsgroups: comp.lang.pascal.borland,fido.ger.pascal