Category : Dbase (Clipper, FoxBase, etc) Languages Source Code
Archive   : ARR.ZIP
Filename : ARR_CR.PRG

 
Output of file : ARR_CR.PRG contained in archive : ARR.ZIP

************************ cr_array.prg *************************

clear

use saldet
*******************************************************************
** replace the above use statement with applicable file name ****
*******************************************************************

set intensity off
set delimiters to '[]'
set delimited on
set color to +7/0
edit_pic = space(25)
col_place = space(2)
head_1 = space(10)
head_2 = space(10)

array_cntr = fcount() && number of fields in database

declare pic_edit[array_cntr] && picture criteria per field
declare col_edit[array_cntr] && column placement
declare name_edit[array_cntr] && name of field
declare hd1_edit[array_cntr] && heading line #1
declare hd2_edit[array_cntr] && heading line #2

set color to 7/0
@ 1,1,23,78 box chr(218)+chr(196)+chr(191)+chr(179)+chr(217)+chr(196)+chr(192)+chr(179)
@2,3 say 'DBF SAY AND/OR GET HEADING HEADING'
@3,3 say 'FIELD COL PICTURE EDIT LINE #1 LINE #2'
col_disp = 3
i=0
for i = 1 to array_cntr
do fill_col
if i < 10
save_col = 'db_pic'+str(i,1,0)
&save_col = ' '
&save_col = pic_edit[i]
save1_col = 'db_col'+str(i,1,0)
&save1_col = 0
&save1_col = val(col_edit[i])
save2_col = 'db_name'+str(i,1,0)
&save2_col = ' '
&save2_col = name_edit[i]
save4_col = 'db_hd1'+str(i,1,0)
&save4_col = ' '
&save4_col = hd1_edit[i]
save5_col = 'db_hd2'+str(i,1,0)
&save5_col = ' '
&save5_col = hd2_edit[i]
else
save_col = 'db_pic'+str(i,2,0)
&save_col = ' '
&save_col = pic_edit[i]
save1_col = 'db_col'+str(i,2,0)
&save1_col = ' '
&save1_col = col_edit[i]
save2_col = 'db_name'+str(i,2,0)
&save2_col = ' '
&save2_col = name_edit[i]
save4_col = 'db_hd1'+str(i,2,0)
&save4_col = ' '
&save4_col = hd1_edit[i]
save5_col = 'db_hd2'+str(i,2,0)
&save5_col = ' '
&save5_col = hd2_edit[i]
endif
next
if .not. arrsave("pic","pic_edit")
? "ERROR ERROR ERROR #1"
endif
if .not. arrsave("col","col_edit")
? "ERROR ERROR ERROR #2"
endif
if .not. arrsave("name","name_edit")
? "ERROR ERROR ERROR #3"
endif
if .not. arrsave("head1","hd1_edit")
? "ERROR ERROR ERROR #4"
endif
if .not. arrsave("head2","hd2_edit")
? "ERROR ERROR ERROR #5"
endif
clear


procedure fill_col
hold_spc = 10-len(fieldname(i))
name_edit[i] = fieldname(i)+space(hold_spc)
if i+4 > 21
call scroll with 4,2,21,77,1,"U"
col_disp = col_disp
else
col_disp = col_disp+1
endif
set color to 7/0
@col_disp,3 say name_edit[i]
set color to +7/0
@col_disp,13 get col_place
@col_disp,25 get edit_pic
@col_disp,53 get head_1
@col_disp,66 get head_2
read
pic_edit[i]=edit_pic
col_edit[i]=col_place
hd1_edit[i]=head_1
hd2_edit[i]=head_2
set color to 7/0
return


  3 Responses to “Category : Dbase (Clipper, FoxBase, etc) Languages Source Code
Archive   : ARR.ZIP
Filename : ARR_CR.PRG

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/