Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.acorn.programmer > #2031

Re: Over 256 Character BASIC string

From Kevin Wells <kev@kevsoft.co.uk>
Newsgroups comp.sys.acorn.programmer
Subject Re: Over 256 Character BASIC string
Date 2012-08-08 15:04 +0100
Organization Aioe.org NNTP Server
Message-ID <dce20dbc52.Kevin@talktalk.net> (permalink)
References (1 earlier) <52b806d0dcchrisjohnson+news@spamcop.net> <f72f8ab852.Kevin@talktalk.net> <52b8de9a49chrisjohnson+news@spamcop.net> <55d213ba52.Kevin@talktalk.net> <RheTr.452007$j37.433394@fx01.am4>

Show all headers | View raw


In message <RheTr.452007$j37.433394@fx01.am4>
          Steve Drain <steve@kappa.me.uk> wrote:

>Kevin Wells wrote:
>> I already go through it one character at a time looking for commas and
>> speech marks, so that looks like the way to go, I take it that the
>> A$=GETS# would be the bit that needs changing.
>
>A few thoughts.
>
>If the file is not large, you could use BGET and read the file
>byte-by-byte, but many would suggest this is not very efficient.

I think BGET would be the easiest solution, but having never used it
before I would appreciate an example that will show me how to ignore the
first two lines, then when it finds a speech mark end that line, and go
as far as line 12.
>
>If you are using strings, for elegance sake, I hope you are not checking
>characters using MID$ or its ilk. INSTR is very fast, and you can set up
>indices to control the searches through the string. I have a FN that
>will deliver a field from a string, taking account of quotes, if that
>would be useful.

Thanks that would be very useful, a I'm using MID$ at the moment, I'm
only using strings as that is what I've always done, and occasionally a
line will be to long, so I'm not against using other means, as I'm
putting the information straight into a text icon.
>
>If you load the whole file into a block of memory, then using a
>FOR...NEXT loop and ?index% is very much the quickest way to check
>character by character, but may well not be as quick as INSTR with a
>string, depending on the data.
>
>Steve
>


-- 
Kev Wells  http://riscos.kevsoft.co.uk/
http://kevsoft.co.uk/   http://kevsoft.co.uk/AleQuest/
ICQ 238580561
Useless Fact 03 You burn 3.5 calories each time you laugh.

Back to comp.sys.acorn.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-07-31 16:48 +0100
  Re: Over 256 Character BASIC string Chris Johnson <chrisjohnson+news@spamcop.net> - 2012-07-31 19:22 +0100
    Re: Over 256 Character BASIC string "David Holden" <SpamBin@apdl.co.uk> - 2012-08-01 07:27 +0000
      Re: Over 256 Character BASIC string Chris Johnson <chrisjohnson+news@spamcop.net> - 2012-08-01 10:52 +0100
    Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-01 19:17 +0100
      Re: Over 256 Character BASIC string jgh@arcade.demon.co.uk - 2012-08-01 20:41 -0700
      Re: Over 256 Character BASIC string Chris Johnson <chrisjohnson+news@spamcop.net> - 2012-08-02 10:39 +0100
        Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-04 18:56 +0100
          Re: Over 256 Character BASIC string Steve Drain <steve@kappa.me.uk> - 2012-08-04 19:56 +0100
            Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-08 15:04 +0100
              Re: Over 256 Character BASIC string jgh@arcade.demon.co.uk (Jonathan Graham Harston) - 2012-08-08 23:15 +0100
                Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-09 15:14 +0100
      Re: Over 256 Character BASIC string Gavin Wraith <gavin@wra1th.plus.com> - 2012-08-02 18:35 +0100
        Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-04 18:58 +0100
      Re: Over 256 Character BASIC string Steve Drain <steve@kappa.me.uk> - 2012-08-03 10:37 +0100
      Re: Over 256 Character BASIC string "Ste (news)" <steve@revi11.plus.com> - 2012-08-10 14:15 +0100
        Re: Over 256 Character BASIC string "Ste (news)" <steve@revi11.plus.com> - 2012-08-10 14:23 +0100
          Re: Over 256 Character BASIC string Kevin Wells <kev@kevsoft.co.uk> - 2012-08-13 19:19 +0100
  Re: Over 256 Character BASIC string druck <news@druck.org.uk> - 2012-07-31 22:20 +0100
  Re: Over 256 Character BASIC string Duncan Moore <duncan.moore@gmx.com> - 2012-08-03 02:11 -0700

csiph-web