[Coco] PRINT vs PRINT USING
coco at jechar.ca
coco at jechar.ca
Tue Mar 31 17:14:14 EDT 2020
On 2020-03-31 16:14, Bill Gunshannon wrote:
> On 3/31/20 3:56 PM, coco at jechar.ca wrote:
>>
>> If I want to print "HELLO" to the screen in a basic09 program
>> I would use.
>>
>> PRINT "HELLO"
>>
>> If instead I to print "HELLO" to a file I can use.
>>
>> PRINT #pathno,"HELLO"
>>
>> Is there any way to send the output of "PRINT USING" to
>> a file?
>>
>> Charlie
>>
>
> According to the manual it is simply:
>
> PRINT #<int exp>, USING <str expr>, <output list>
>
> bill
When I try the syntax you suggest I get a compile error.
OPEN #pathno,saveat$:WRITE
PRINT #pathno,"TEST"
FOR y=1 TO 19
FOR x=1 TO 21
PRINT #pathno," ";
PRINT #pathno, USING "H", quilt(x,y);
NEXT x
PRINT #pathno
NEXT y
CLOSE #pathno
Everything worked before I tryed to send it to a file.
Also It works if except for the "PRINT USING" line.
So it is not an issue with the pathno or saveat$ varibles.
Which are of type BYTE and STRING.
PS THE COMPILE ERROR POINTER POINTS TO JUST BEFORE "USING"
Charlie.
More information about the Coco
mailing list