Evening all,
I have a simple question,
Is it possible to create a string using INPUT where the leading spaces are accepted as characters?
Currently my code is similar to this
INPUT"Text ";a$
PRINT a$
IF text inputted is " test"
the result is
"test"
The result i want in a$ is " test"
Can anyone help
Regards Ric
Leading spaces INPUT
-
- Posts: 222
- Joined: Tue 17 Apr 2018, 21:03
Leading spaces INPUT
Kind Regards Ric.
6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
-
- Posts: 78
- Joined: Sat 23 Jun 2018, 15:51
Re: Leading spaces INPUT
It looks like the FNinput in the NOWAIT library will do that for you.
Z
Z
-
- Posts: 222
- Joined: Tue 17 Apr 2018, 21:03
Re: Leading spaces INPUT
Perfect.
Thanks Z
Ric
Thanks Z
Ric
Kind Regards Ric.
6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
Re: Leading spaces INPUT
An alternative would be to use INPUT LINE? From the manual: "The item input is taken as is, including commas, quotes and leading spaces. "
Best wishes,
D
Best wishes,
D