Jump to content
IGNORED

how to list files horizontally on 2c


newTIboyRob

Recommended Posts

Does anyone remember how to list files from the CAT command so they appear horizontally instead of vertically on the screen? This one disk I have has a slew of files and I would like to view them all at one time in PR#3 80 column mode.

 

(I assume this command would also work going back to 40 column using PR#0)

 

Thanks

Link to comment
Share on other sites

You can do it in Applesoft by reading the file names into an array, then printing the array using a semi-colon and HTAB instead of a return.  The CAT command by itself cannot print multiple files horizontally.  Since file names can be 15 characters, and 1 for a space, 5 columns of file names can be displayed.

 

You can limit the files displayed by using the ,T directive, such as CAT,TDIR or CAT,TTXT or CAT,TBAS  CAT,TSYS   CAT,TBIN

 

Edited by Iamgroot
Link to comment
Share on other sites

I don't know if this is exactly what you meant, as it does not use HTAB nor the CAT command within the program, but it does use the array concept, read and data statements:

 

5 HOME

10 FOR X=1 TO 6

20 READ F$

30 PRINT F$; " ";

40 NEXT X

50 DATA FILE1,FILE2,FILE3,FILE4,FILE5,FILE6

 

achieving...

FILE1  FILE 2  FILE3  FILE4  FILE5  FILE6

 

But what I was originally aiming for was using the CAT command within that program to achieve that same result. You mentioned that the CAT command by itself cannot print multiple files horizontally, but how exactly would it appear in the program used with HTAB and ; ?    So it would be like... it is searching for a file, found it, listed it, found the next one, but listed it horizontally, etc. Would you tweak the program for me or show me what you came up with?  

Link to comment
Share on other sites

Then once we nail the above program, I would like to just add one more concept in there which is using the GET K$ with the CAT command so that let's say in 40 column, there are 50 total files on the disk, but after, say file #15 is listed from the CAT, we had inserted the GET K$ command using it as a pause with a statement of "Press Any Key To Continue", then once any key is pressed, the CAT command continues listing the remaining file #'s 16 through 50.

 

Is interrupting the CAT command with the GET K$ key strike concept like that even possible?  Over my head, but maybe not over yours!

 

Groot, see what you can do here and with the above, and/or if anyone else can help with the 2 "challenges"?

Link to comment
Share on other sites

21 hours ago, Iamgroot said:

You can do it in Applesoft by reading the file names into an array, then printing the array using a semi-colon and HTAB instead of a return.  The CAT command by itself cannot print multiple files horizontally.  Since file names can be 15 characters, and 1 for a space, 5 columns of file names can be displayed.

 

You can limit the files displayed by using the ,T directive, such as CAT,TDIR or CAT,TTXT or CAT,TBAS  CAT,TSYS   CAT,TBIN

 

DOS 3.3 can have 30 Character File names, with Spaces..  ProDOS is limited to 15 Characters..

 

The CATALOG Command in ProDOS is better on 80 Column, use the CAT Command for 40 Columns.

 

I would think that a Driver for ProDOS could be made to get a Double Wide CAT Catalog...

 

MarkO

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...