Source code of GREYcells instograf (Part-I - Total - Approx. 15,000 lines)
Written in Clipper with the graphics library Flipper for providing GUI interface !
GREYcells instograf
Designed & developed by J.V.Ravichandran
Started in October 1994 
Completed in December 1995/96 (alongwith GREYcells Accounts for manufacturing units)
GREYcells instograf was featured in the news section of PcQuest June 1995
I had sent GREYcells instograf on my nomination for the Young India Business
Achiever award, 1996, conducted by Siesta, Siesta & Siesta communications, 
held in Mumbai, 1996.

 

The program
Alert.prg
          pat_setfil(1)
          fbox(150,100,575,300,nbarclr)
          fbox(151,101,574,121,0)
          fbox(151,101,180,120,8)
          get_getclr(nbartxtclr,nbarclr,nbartxtclr,nbarclr,nbartxtclr,nbarclr)
          font_new(nfont1)
          get_say(104,325,"GREYcells")
          Say_fmt(ALLTRIM("|(159,110)CF8 KF0 KB8 A SP0 DR R1|0"))
          font_new(nfont1)
          get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
          get_say(135,160,"Alert ! This is a shareware software. Please send a cheque of")
          get_say(155,160,"Rs. 5,000.00 only or TWO HUNDRED dollars drawn in favor of")
          get_say(175,160,"SEMANTIX Computers, New Delhi to ")
          get_say(200,160,"Mr.J.V.Ravichandran, Proprietor/Software Architect/Consultant,")
          get_say(220,160,"Semantix Computers, B-10, Triveni Apartments, Near 'H' Block, ")
          get_say(240,160,"Vikas puri, New Delhi-110 018 to become a registered owner of")
          get_say(260,160,"the software and to access all the features in the software.")
          get_say(280,160,"Press any key to continue....")
          KEY_PRESS()
         RETURN
Bar.prg
SET_TYPE(1,3)
SET_TYPE(2,3)
SET_TYPE(3,3)
SET_TYPE(4,3)
SET_TYPE(5,3)
SET_TYPE(6,3)
chk=1
return
Default.prg
grf_colors(,,,,,,)
return
Dele.prg
font_new(nfont1)
get_getclr(nbotbartxtclr,nbotbarclr,nbotbartxtclr,nbotbarclr,nbotbartxtclr,nbotbarclr)
get_say(329,420,"File")
get_getclr(nbotscrtxtclr,nbotscrclr,nbotscrtxtclr,nbotscrclr,nbotscrtxtclr,nbotscrclr)
get_say(375,265,"Filename -")
                                         DECLARE aFiles[ADIR("*.GRF")]
                                         ADIR("*.GRF",aFiles)
                                         h_ans=MENU_ONLY( aFiles, 50, 10, 4, 2, 10 )
                                   if h_ans=0
                                      mev='y'
                                      mn='n'
                                      fil_name=space(12)
                                   endif
                                       if h_ans>0
                                         fil_name=aFiles[h_ans]
                                         get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                                         get_say(375,355,fil_name)
                                         fil_name=get_get(375,355,fil_name)
                                         sele 1
                                         use greydata\file_g
                                         locate for alltrim(upper(fil_name))=alltrim(upper(fyl_name))
                                      if found()
                                        dele
                                        pack
                                        FERASE(alltrim(UPPER(fil_name)))
                                        get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                                        get_say(375,265,"File succesfully deleted.")
                                        get_say(390,265,"Press any key to continue....")
                                        key_press()
                                        do bott
                                      endif
                                      if !found()
                                           do bott
                                           font_new(nfont1)
                                        if nscreenclr1=15
                                           nfgtxtclr=0
                                      else
                                        if nscreenclr1=0
                                           nfgttxtclr=15
                                      else
                                           nfgtxtclr=15
                                        endif
                                        endif
                                           get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                                           get_say(375,265,"File does not exist.")
                                           get_say(390,265,"Press any key to continue....")
                                           key_press()
                                           do bott
                                        endif
                                        use
                                        sele 2
                                        use greydata\tempdata
                                        locate for alltrim(upper(fil_name))=alltrim(upper(fy_name))
                                        if found()
                                         dele
                                         pack
                                         use
                                         get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                                         get_say(375,265,"File succesfully deleted from database.")
                                         get_say(390,265,"Press any key to continue....")
                                         key_press()
                                        endif
                                          if !found()
                                            do bott
                                            get_say(375,265,"File does not exist.")
                                            key_press()
                                            do bott
                                          endif
                                         endif
return 
design2.prg
nkey=.25
PAT_SETFIL(1)
FBOX(0,0,620,425,15)
FBOX(2,2,618,22,0)
pat_setfil(3)
FBOX(1,23,6,419,0)
FBOX(1,419,619,424,0)
FBOX(614,23,619,424,0)
say_fmt(ALLTRIM("|(280,18)CF8 KF15 KB0 A SP0 DR|GREYcells"))
FLINE(7,53,613,53,0)
FLINE(100,100,520,100,0)
FLINE(100,100,100,375,0)
FLINE(520,100,520,375,0)
FLINE(100,375,520,375,0)
say_fmt(ALLTRIM("|(225,290)CF5 KF0 A SP0 DR|GREYcells"))
say_fmt(ALLTRIM("|(395,270)CF4 KF0 A SP0 DR|Tm"))
*
FLINE(340,295,390,295,0)
FLINE(100,310,520,310,0)
*
font_new(nfont2)
get_getclr(0,15,0,15,0,15)
get_say(60,100,"E v a l u a t i o n  c o p y")
*
say_fmt(ALLTRIM("|(110,125)CF4 KF0 A SP0 DR|GREYcells is the trade mark of SEMANTIX computers. Under the new"))
say_fmt(ALLTRIM("|(125,140)CF4 KF0 A SP0 DR|copyright law any attempt to copy the software for distribution or"))
say_fmt(ALLTRIM("|(125,155)CF4 KF0 A SP0 DR|for any other purpose without proper identification or registration"))
say_fmt(ALLTRIM("|(125,170)CF4 KF0 A SP0 DR|number will be deemed as a cognizable offence under the Indian penal"))
say_fmt(ALLTRIM("|(125,185)CF4 KF0 A SP0 DR|code and may lead to immediate imprisonment."))
say_fmt(ALLTRIM("|(125,225)CF4 KF0 A SP0 DR|(c) SEMANTIX Computers, J.V.RAVICHANDRAN , 1995."))
*say_fmt(ALLTRIM("|(125,215)CF4 KF0 A SP0 DR|(c) Microsoft corp."))
*say_fmt(ALLTRIM("|(125,230)CF4 KF0 A SP0 DR|(c) Nantucket corp., inc."))
*say_fmt(ALLTRIM("|(125,245)CF4 KF0 A SP0 DR|(c) Assembler Software Manufacturers, inc."))
pat_setfil(1)
fbox(105,315,515,370,0)
say_fmt(ALLTRIM("|(110,330)CF4 KF15 KB0 A SP0 DR|"))
say_fmt(ALLTRIM("|(110,345)CF4 KF15 KB0 A SP0 DR|           Evaluation copy."))
say_fmt(ALLTRIM("|(110,360)CF4 KF15 KB0 A SP0 DR|"))
say_fmt(alltrim("|(150,445)CF8 KF15 KB0 A SP0 DR|(c) Semantix Computers   J.V.RAVICHANDRAN   June 1995."))
*
pat_setfil(1)
FCIRCLE( 150, 267, 11, 0)
*
fline(135,230,135,255,0)
fline(135,230,160,230,0)
fline(160,230,135,255,0)
*
fline(170,275,185,290,0)
fline(170,275,155,290,0)
fline(155,290,185,290,0)
*
text
cbr=1
scr_r=0
scr_rr=20
scr_c=0
scr_cc=640
 n_key=lastkey()
do while n_key=nkey
 inkey(nkey)
 n_key=lastkey()
 pat_setfil(1)
 fbox(scr_c,scr_r,scr_cc,scr_rr,0)
 scr_rr=scr_rr+20
 cbr++
enddo
endtext
return
Drawlogo.prg
cls_screen()
pat_setfil(1)
FCIRCLE( 45, 433, 11, 12)
*
col=30
col1=50
row=390
row1=415
cttr=0
do while cttr<10
fline(col,row,col,row1,9)
fline(col,row,col1,row,9)
fline(col1,row,col,row1,9)
col++
row1--
col1--
row++
cttr++
enddo
fline(col1+1,row,col,row1,9)
*
col=65
coll=50
col1=80
row=445
row1=460
cttr=0
do while cttr<15
fline(col,row,col1,row1,15)
fline(col,row,coll,row1,15)
fline(coll,row1,col1,row1,15)
row++
coll++
col1--
cttr++
enddo
*
         cfil="tempmin.pic"
         nPIChandl=fpic_create(cfil,1)
         nindex=fpic_get(25,385,90,470,nindex,nPIChandl)
       if nindex=-1
         mpicok='n'
        else
         mpicok='y'
       endif
return

 

Beg_help.prg
         pat_setfil(1)
         fbox(150,55,600,400,15)
         fbox(150,55,600,75,0)
         pat_setfil(3)
         fbox(150,75,155,400,0)
         fbox(150,395,600,400,0)
         fbox(595,75,600,400,0)
         say_fmt(ALLTRIM("|(360,68)CF4 KF15 KB0 A SP0 DR|Help"))
         Say_fmt(ALLTRIM("|(160,62)CF8 KF15 KB0 A SP0 DR R1|0"))
         font_new(nfont3)
         get_getclr(0,15,0,15,0,15)
         get_say(95,165,"The beginning ...")
         font_new(nfont1)
         get_say(125,160,"The initial screen of GREYcells instograf. The top oval button is")
         get_say(145,160,"activated by the 'F3' key and the left buttons with the alphabets")
         get_say(165,160,"embedded in them are activated directly by the press of any alphabet")
         get_say(185,160,"displayed in the menu. The function of each menu item is elucidated on")
         get_say(205,160,"the top of the screen. After the press of one of the left buttons the")
         get_say(225,160,"corresponding function will be displayed in the screen. All the oval")
         get_say(245,160,"buttons throughout GREYcells instograf are activated by the F3 key. ")
         get_say(375,175,"For more help...Press Page Down key")
         ctr++
         return
Bott.prg
if nbotbarclr=0
   nbarlineclr=15
   nbotbartxtclr=15
  else
   if nbotbarclr=15
    nbarlineclr=0
    nbotbartxtclr=0
   else
    nbotbartxtclr=0
  endif
endif
if nbotscrclr=0
   nlineclr=15
   nbotscrtxtclr=15
  else
   if nbotbarclr=15
    nlineclr=0
    nbotscrtxtclr=0
   else
    nlineclr=0
    nbotscrtxtclr=0
  endif
endif
             Pat_setfil(1)
             fbox(250,325,612,430,nbotscrclr)
             fbox(251,326,611,350,nbotbarclr)
             fbox(252,327,275,348,8)
             fline(251,326,612,326,nbarlineclr)
             fline(251,348,612,348,nbarlineclr)
             fline(612,326,612,348,nbarlineclr)
             fline(251,326,251,348,nbarlineclr)
             Say_fmt(ALLTRIM("|(255,334)CF8 KF0 KB8 A SP0 DR R1|0"))
             font_new(nfont1)
             fline(250,325,250,430,nlineclr)
             fline(250,325,612,325,nlineclr)
             fline(612,325,612,430,nlineclr)
             fline(250,430,612,430,nlineclr)
             return

 

color.prg
clr_menu(drop_menu)
clr_menu(drop_menuu)
clr_menu(left_menu)
clr_menu(down_menu7)
clr_menu(drop_menu6)
clr_menu(down_menu5)
clr_menu(down_menu4)
clr_menu(drop_menu2)
clr_menu(down_menu1)
clr_menu(down_menu)
clr_menu(drop_menu9)
clr_menu(right_menu)
clr_menu(drop_menu8)
clr_menu(drop_menu7)
clr_menu(drop_menu6)
clr_menu(drop_menu5)
clr_menu(drop_menu4)
clr_menu(drop_menu3)
clr_menu(drop_menu2)
xxtt=0
p_menu=0
if nbarclr=0
   nlineclr=15
  else
   if nbarclr=15
    nlineclr=0
  endif
endif
if nscreenclr1=0
 nftxtclr=0
 ntclr=15
else
if nscreenclr1=15
 nftxtclr=15
 ntclr=0
 else
  nftxtclr=nfgtxtclr
  ntclr=nscreenclr1
endif
endif
*
colctr=0
men='y'
         item1="Desktop color"
         item2="Menu colors"
*         nPIChandl=fpic_create(cfil,10)
*         sele 1
*         use greydata\pichandl
*         dele all for alltrim(upper(cfil))=alltrim(upper(filname))
*         pack
*         append blank
*         replace pichand with nPIChandl
*         replace filname with cfil
*         use
*         nindx=fpic_get(190,125,485,300,nindx,nPIChandl)
  do colorscr
  r=5
  c=5
dtp_menu=MENU_OPEN( nfont7, 6, 0, 1, 1, 4, 1)
MENU_ITEM(dtp_menu,r,c,asc("1"),0,"Desktop color                 ",1,0)
MENU_ITEM(dtp_menu,r+1,c,asc("2"),0,"Desktop bar color             ",1,0)
MENU_ITEM(dtp_menu,r+2,c,asc("3"),0,"Desktop bar text color        ",1,0)
MENU_ITEM(dtp_menu,r+3,c,asc("4"),0,"Initial screen color          ",1,0)
MENU_ITEM(dtp_menu,r+4,c,asc("5"),0,"Initial screen text color     ",1,0)
MENU_ITEM(dtp_menu,r+5,c,asc("6"),0,"Foreground screen text color  ",1,0)
MENU_ITEM(dtp_menu,r+6,c,asc("7"),0,"Title text color (instograf)  ",1,0)
MENU_ITEM(dtp_menu,r+7,c,asc("8"),0,"Title background color        ",1,0)
MENU_ITEM(dtp_menu,r+8,c,asc("9"),0,"Bottom screen color           ",1,0)
MENU_ITEM(dtp_menu,r+9,c,asc("10"),0,"Bottom screen bar color       ",1,0)
MENU_ITEM(dtp_menu,r+10,c,asc("11"),0,"Close                         ",1,0)
menu_clr=MENU_OPEN( nfont7, 6, 0, 1, 1, 4, 1)
MENU_ITEM(menu_clr,r,c,asc("1"),0,"Menu box color                ",1,0)
MENU_ITEM(menu_clr,r+1,c,asc("2"),0,"Selected background color     ",1,0)
MENU_ITEM(menu_clr,r+2,c,asc("3"),0,"Selected foreground color     ",1,0)
MENU_ITEM(menu_clr,r+3,c,asc("4"),0,"Non-selected background color ",1,0)
MENU_ITEM(menu_clr,r+4,c,asc("5"),0,"Non-selected foreground color ",1,0)
MENU_ITEM(menu_clr,r+5,c,asc("6"),0,"3-D menu (yes/no)             ",1,0)
MENU_ITEM(menu_clr,r+6,c,asc("7"),0,"Menu border type              ",1,0)
MENU_ITEM(menu_clr,r+7,c,asc("8"),0,"Menu border color             ",1,0)
MENU_ITEM(menu_clr,r+8,c,asc("9"),0,"Menu border thickness         ",1,0)
MENU_ITEM(menu_clr,r+9,c,asc("10"),0,"Shadow type                   ",1,0)
MENU_ITEM(menu_clr,r+10,c,asc("11"),0,"Shadow color                  ",1,0)
MENU_ITEM(menu_clr,r+11,c,asc("12"),0,"Shadow thickness              ",1,0)
MENU_ITEM(menu_clr,r+12,c,asc("13"),0,"Foreground 3-D color          ",1,0)
MENU_ITEM(menu_clr,r+13,c,asc("14"),0,"Background 3-D color          ",1,0)
MENU_ITEM(menu_clr,r+14,c,asc("15"),0,"Selected foreground text color",1,0)
MENU_ITEM(menu_clr,r+15,c,asc("16"),0,"Selected background text color",1,0)
MENU_ITEM(menu_clr,r+16,c,asc("17"),0,"Default                       ",1,0)
MENU_ITEM(menu_clr,r+17,c,asc("18"),0,"Close                         ",1,0)
drop_menuu=MENU_OPEN( nfont5, 6, 0, 1, 1, 4, 1)
MENU_ITEM(drop_menuu,2,14,asc("1"),0," 1 ",1,0)
MENU_ITEM(drop_menuu,3,14,asc("2"),0," 2 ",1,0)
MENU_ITEM(drop_menuu,4,14,asc("3"),0," 3 ",1,0)
MENU_ITEM(drop_menuu,5,14,asc("4"),0," 4 ",1,0)
MENU_ITEM(drop_menuu,6,14,asc("5"),0," 5 ",1,0)
MENU_ITEM(drop_menuu,7,14,asc("6"),0," 6 ",1,0)
MENU_ITEM(drop_menuu,8,14,asc("7"),0," 7 ",1,0)
MENU_ITEM(drop_menuu,9,14,asc("8"),0," 8 ",1,0)
MENU_ITEM(drop_menuu,10,14,asc("9"),0," 9 ",1,0)
MENU_ITEM(drop_menuu,11,14,asc("0"),0,"10 ",1,0)
MENU_ITEM(drop_menuu,12,14,asc("11"),0,"11 ",1,0)
MENU_ITEM(drop_menuu,13,14,asc("12"),0,"12 ",1,0)
MENU_ITEM(drop_menuu,14,14,asc("13"),0,"13 ",1,0)
MENU_ITEM(drop_menuu,15,14,asc("14"),0,"14 ",1,0)
MENU_ITEM(drop_menuu,16,14,asc("15"),0,"15 ",1,0)
*
p_menu=MENU_OPEN( nfont5, 6, 0, 1, 1, 4, 1)
MENU_ITEM(p_menu,7,11,ASC("1"),0,"Close",1,0)
*
do while men='y'
  key_press()
  do case
      case kp_scan()=61
        ans=MENU_ONLY(p_menu)
            if ans=1
              if coloron='y'
                sele 1
                use greydata\color EXCLUSIVE
                locate for status="UPDATED"
                replace screenclr with nscreenclr1
                replace barclr with nbarclr
                replace bartxtclr with nbartxtclr
                replace fgtxtclr with nfgtxtclr
                replace titleclr with ntitleclr
                replace titletxt with ntitletxt
                replace initclr with ninitclr
                replace inittxt with ninittxt
                replace botbarclr with nbotbarclr
                replace botscrclr with nbotscrclr
                use
              endif
              IF  menuclron='y'
                sele 2
                use greydata\menuclr EXCLUSIVE
                locate for status="UPDATED"
                replace boxclr with mboxclr
                replace selbg with mselbg
                replace selfg with mselfg
                replace nonselbg with mnonselbg
                replace nonselfg with mnonselfg
                replace n3don with mn3don
                replace nbodrtyp with mnbodrtyp
                replace nbodrthk with mnbodrthk
                replace shadtyp with mshadtyp
                replace shadclr with mshadclr
                replace shadthk with mshadthk
                replace n3dfg with mn3dfg
                replace n3dbg with mn3dbg
                replace selfgclr with mselfgclr
                replace selbgclr with mselbgclr
                use
              ENDIF
                if menuclron='n' .or. coloron='n'
                  colored='n'
                 else
                if menuclron='y' .or. coloron='y'
                  colored='y'
                endif
                endif
                if colored='y'
                  do initcolr
                  colored='n'
                endif
                men='n'
            endif
      case kp_scan()=77                   && Right
                  if z=0
                       get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                       font_new(nfont1)
                       get_say(menu_row,menu_col+5,item1)
                       if menu_col<345
                         menu_col=menu_col+135
                         menu_coll=menu_coll+135
                       endif
                       get_getclr(nftxtclr,ntclr,nftxtclr,ntclr,nftxtclr,ntclr)
                       font_new(nfont1)
                       get_say(menu_row,menu_col+5,item2)
*                       menu_sleep(mem)
*                       menu_wake(sam_menu)
                  endif
                  if z<1
                    z++
                  endif
      case kp_scan()=75                         && Left
                  if z=1
                       get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
                       font_new(nfont1)
                       get_say(menu_row,menu_col+5,item2)
                       if menu_col>210
                          menu_col=menu_col-135
                          menu_coll=menu_coll-135
                       endif
                       get_getclr(nftxtclr,ntclr,nftxtclr,ntclr,nftxtclr,ntclr)
                       font_new(nfont1)
                       get_say(menu_row,menu_col+5,item1)
*                       menu_wake(sam_menu)
*                       menu_sleep(mem)
                 endif
                  if z>0
                    z--
                  endif
     case kp_scan()=28
         if z=0
             dtp_ans=MENU_ONLY(dtp_menu)
             coloron='y'
           if dtp_ans=1
             do menuclr
             nscreenclr1=colr
             do samplscr
           else
           if dtp_ans=2
             do menuclr
             nbarclr=colr
             do samplscr
           else
           if dtp_ans=3
             do menuclr
             nbartxtclr=colr
             do samplscr
           else
           if dtp_ans=4
             do menuclr
             ninitclr=colr
             do samplscr
           else
           if dtp_ans=5
             do menuclr
             ninittxt=colr
             do samplscr
           else
           if dtp_ans=6
             do menuclr
             nfgtxtclr=colr
             do samplscr
           else
           if dtp_ans=7
             do menuclr
             ntitletxt=colr
           else
           if dtp_ans=8
             do menuclr
             ntitleclr=colr
           else
           if dtp_ans=9
            do menuclr
            nbotscrclr=colr
           else
           if dtp_ans=10
            do menuclr
            nbotbarclr=colr
           else
           if dtp_ans=11
                do colorscr
           endif
           endif
           endif
           endif
           endif
           endif
           endif
           endif
           endif
           endif
           endif
          else
           if z=1
             clr_ans=MENU_ONLY(menu_clr)
                   if clr_ans=1
                    do menuclr
                    menuclron='y'
                    mboxclr=colr
                    do samplscr
                   else
                   if clr_ans=2
                    do menuclr
                    mselbg=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=3
                    do menuclr
                    mselfg=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=4
                    do menuclr
                    mnonselbg=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=5
                    do menuclr
                    mnonselfg=colr
                    do samplscr
                    menuclron='y'
                   else
                   if clr_ans=6
                    n3dctr++
                    if n3dctr>1
                      n3dctr=0
                    endif
                    mn3don=n3dctr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=7
                    do number
text
                    menuctr++
                    if menuctr>1
                      menuctr=0
                    endif
endtext
                    mnbodrtyp=xxtt
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=8
                    do menuclr
                    mnbodrclr=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=9
                    do number
                    mnbodrthk=xxtt
                    menuclron='y'
                    do samplscr
                   else
                else
                   if clr_ans=10
                    mshadtyp++
                    menuclron='y'
                    if mshadtyp>1
                     mshadtyp=0
                    endif
                    do samplscr
                   else
                   if clr_ans=11
                    do menuclr
                    mshadclr=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=12
                    do number
                    mshadthk=xxtt
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=13
                    do menuclr
                    mn3dfg=colr
                    menuclron='y'
                    do samplscr
                   else
                else
                   if clr_ans=14
                    do menuclr
                    mn3dbg=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=15
                    do menuclr
                    mselfgclr=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=16
                    do menuclr
                    mselbgclr=colr
                    menuclron='y'
                    do samplscr
                   else
                   if clr_ans=17
                      menuclron='n'
                      colored='n'
                   else
                   if clr_ans=18
                       do colorscr
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
                   endif
            endif
            endif
          otherwise
           menu_wake(sam_menu)
           menu_wake(mem)
        endcase
    enddo
    xxtt=0
return

 

colorscr.prg
if nbarclr=0
   nlineclr=15
  else
   if nbarclr=15
    nlineclr=0
  endif
endif
         PAT_SETFIL(1)
         FBOX(200,145,475,255,nscreenclr1)
         FBOX(230,146,474,171,nbarclr)
         FBOX(202,147,228,169,8)
         fbox(228,146,230,171,0)
         fline(202,147,227,147,15)
         fline(202,147,202,169,15)
         fline(200,145,474,145,nlineclr)
         fline(200,146,200,171,nlineclr)
         fline(474,145,474,171,nlineclr)
         fline(200,171,474,171,nlineclr)
         pat_setfil(3)
         fbox(200,171,204,255,nlineclr)
         fbox(200,251,475,255,nlineclr)
         fbox(471,171,475,255,nlineclr)
         Say_fmt(ALLTRIM("|(207,157)CF8 KF0 KB8 A SP0 DR R1|0"))
         if nscreenclr1=15
            nfgtxtclr=0
            nlineclr=0
             else
              if nscreenclr1=0
                nfgttxtclr=15
                nlineclr=15
              else
                nfgtxtclr=15
             endif
            endif
         FONT_NEW(nfont5)
         get_getclr(nbartxtclr,nbarclr,nbartxtclr,nbarclr,nbartxtclr,nbarclr)
         get_say(151,295,"GREYcells")
         get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
         item1="Desktop color"
         item2="Menu colors"
         font_new(nfont1)
         get_say(175,215,item1)
         get_say(175,350,item2)
         mem=0
         sam_menu=0
         mem=menu_open(nfont17,6,0,0,0,0,0)
         menu_item(mem,5,6,12,1,chr(12),1,0)
         menu_wake(mem)
         sam_menu=MENU_OPEN( nfont7, 6, 0, 1, 1, 4, 1)
         MENU_ITEM(sam_menu,11,25,asc("1"),0,"Sample",1,0)
         MENU_ITEM(sam_menu,12,25,asc("2"),0,"Menu  ",1,0)
         MENU_WAKE(sam_menu)
         z=0
         e=0
         c=0
         menu_row=175
         menu_col=210
         menu_coll=325
         menu_row1=190
         get_getclr(nftxtclr,ntclr,nftxtclr,ntclr,nftxtclr,ntclr)
         font_new(nfont1)
         get_say(menu_row,menu_col+5,item1)
return
dat_save.prg
             font_new(nfont1)
             get_say(328,400,"File")
             get_getclr(nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1,nfgtxtclr,nscreenclr1)
             get_say(375,265,"Filename -")
             get_say(400,300,"Important! Please key in extension '.GRF' without fail.")
             fil_name=get_get(375,355,fil_name)
             Say_fmt(ALLTRIM("|(255,334)CF8 KF0 KB8 A SP0 DR R1|0"))
             font_new(nfont1)
use greydata\tempdata
locate for upper(fil_name)=fy_name
if found()
 exist='y'
 ELSE
  exist='n'
endif
if exist='y'
if xs='y    '
  legg=1
  else
   if xs='yy   '
    legg=2
     else
      if xs='yyy  '
        legg=3
         else
          if xs='yyyy '
            legg=4
             else
              if xs='yyyyy'
                legg=5
              endif
           endif
         endif
      endif
    endif
      locate for upper(fil_name)=fy_name
      repl fy_name with upper(fil_name)
      repl g_title with gt
      repl g_font with gf
      repl graf_type with gr_type
      repl x_title with xax
      repl y_title with yax
      repl three_d with val(threed)
      repl x_data with xd
      repl x_data1 with xd1
      repl x_data2 with xd2
      repl x_data3 with xd3
      repl x_data4 with xd4
      repl x_data5 with xd5
      repl x_data6 with xd6
      repl x_data7 with xd7
      repl x_data8 with xd8
      repl x_data9 with xd9
      repl y_data with yd
      repl y_data1 with yd1
      repl y_data2 with yd2
      repl y_data3 with yd3
      repl y_data4 with yd4
      repl y_data5 with yd5
      repl y_data6 with yd6
      repl y_data7 with yd7
      repl y_data8 with yd8
      repl y_data9 with yd9
      repl z_data with zd
      repl z_data1 with zd1
      repl z_data2 with zd2
      repl z_data3 with zd3
      repl z_data4 with zd4
      repl z_data5 with zd5
      repl z_data6 with zd6
      repl z_data7 with zd7
      repl z_data8 with zd8
      repl z_data9 with zd9
      repl w_data with qd
      repl w_data1 with qd1
      repl w_data2 with qd2
      repl w_data3 with qd3
      repl w_data4 with qd4
      repl w_data5 with qd5
      repl w_data6 with qd6
      repl w_data7 with qd7
      repl w_data8 with qd8
      repl w_data9 with qd9
      repl r_data with wd
      repl r_data1 with wd1
      repl r_data2 with wd2
      repl r_data3 with wd3
      repl r_data4 with wd4
      repl r_data5 with wd5
      repl r_data6 with wd6
      repl r_data7 with wd7
      repl r_data8 with wd8
      repl r_data9 with wd9
      repl graf_clr1 with colr
      repl graf_clr2 with colr1
      repl graf_clr3 with colr2
      repl graf_clr4 with colr3
      repl graf_clr5 with colr4
      repl graf_clr6 with colr6
      repl graf_clr7 with colr7
      repl leg_tit1 with lg
      repl leg_tit2 with lg1
      repl leg_tit3 with lg2
      repl leg_tit4 with lg3
      repl leg_tit5 with lg4
      repl num_of_leg with legg
      repl xax_tit with xaxt
      repl xax_tit1 with xaxt1
      repl xax_tit2 with xaxt2
      repl xax_tit3 with xaxt3
      repl xax_tit4 with xaxt4
      repl xax_tit5 with xaxt5
      repl xax_tit6 with xaxt6
      repl xax_tit7 with xaxt7
      repl xax_tit8 with xaxt8
      repl xax_tit9 with xaxt9
      repl num_of_xax with str(xtt)
    if gr_type#'PIE'
      repl g_type with typ
    endif
      repl lege_are with leg_area
       else
    if exist='n'
    FCREATE(fil_name,0)
if xs='y    '
  legg=1
  else
   if xs='yy   '
    legg=2
     else
      if xs='yyy  '
        legg=3
         else
          if xs='yyyy '
            legg=4
             else
              if xs='yyyyy'
                legg=5
              endif
           endif
         endif
      endif
    endif
      use greydata\tempdata
      append blank
      repl fy_name with upper(fil_name)
      repl g_title with gt
      repl g_font with gf
      repl x_title with xax
      repl y_title with yax
      repl graf_type with gr_type
      repl three_d with val(threed)
      repl x_data with xd
      repl x_data1 with xd1
      repl x_data2 with xd2
      repl x_data3 with xd3
      repl x_data4 with xd4
      repl x_data5 with xd5
      repl x_data6 with xd6
      repl x_data7 with xd7
      repl x_data8 with xd8
      repl x_data9 with xd9
      repl y_data with yd
      repl y_data1 with yd1
      repl y_data2 with yd2
      repl y_data3 with yd3
      repl y_data4 with yd4
      repl y_data5 with yd5
      repl y_data6 with yd6
      repl y_data7 with yd7
      repl y_data8 with yd8
      repl y_data9 with yd9
      repl z_data with zd
      repl z_data1 with zd1
      repl z_data2 with zd2
      repl z_data3 with zd3
      repl z_data4 with zd4
      repl z_data5 with zd5
      repl z_data6 with zd6
      repl z_data7 with zd7
      repl z_data8 with zd8
      repl z_data9 with zd9
      repl w_data with qd
      repl w_data1 with qd1
      repl w_data2 with qd2
      repl w_data3 with qd3
      repl w_data4 with qd4
      repl w_data5 with qd5
      repl w_data6 with qd6
      repl w_data7 with qd7
      repl w_data8 with qd8
      repl w_data9 with qd9
      repl r_data with wd
      repl r_data1 with wd1
      repl r_data2 with wd2
      repl r_data3 with wd3
      repl r_data4 with wd4
      repl r_data5 with wd5
      repl r_data6 with wd6
      repl r_data7 with wd7
      repl r_data8 with wd8
      repl r_data9 with wd9
      repl graf_clr1 with colr
      repl graf_clr2 with colr1
      repl graf_clr3 with colr2
      repl graf_clr4 with colr3
      repl graf_clr5 with colr4
      repl graf_clr6 with colr6
      repl graf_clr7 with colr7
      repl leg_tit1 with lg
      repl leg_tit2 with lg1
      repl leg_tit3 with lg2
      repl leg_tit4 with lg3
      repl leg_tit5 with lg4
      repl xax_tit with xaxt
      repl xax_tit1 with xaxt1
      repl xax_tit2 with xaxt2
      repl xax_tit3 with xaxt3
      repl xax_tit4 with xaxt4
      repl xax_tit5 with xaxt5
      repl xax_tit6 with xaxt6
      repl xax_tit7 with xaxt7
      repl xax_tit8 with xaxt8
      repl xax_tit9 with xaxt9
      repl num_of_leg with leg
      Repl num_of_XAX with str(xtt)
    if gr_type#'PIE'
      repl g_type with typ
    endif
      repl lege_are with leg_area
    endif
 endif
 cls_screen()
 clos all
return

 

Data.prg
chexk='y'
do while iy='y'
KEY_PRESS()
do case
 case  kp_scan()=27
    tone(250,5)
    iy='n'
    pic_put(0,0,1)
    mn='n'
    nmn='y'
 case kp_scan()=28
   do keyindat
endcase
enddo
nmn=' '
mn=' '
*pic_put(0,0,1)
*
return
Data_scr.prg
be_g='n'
chek='n'
cttr=1
cfk=0
if oper='y'
 pic_put(0,0,1)
 pic_free()
 key_press()
else
 pat_setfil(1)
 fbox(48,50,590,350,8)
 fbox(50,52,588,72,0)
 pat_setfil(3)
 fbox(48,72,50,349,0)
 fbox(48,347,589,349,0)
 fbox(587,72,589,349,0)
 say_fmt(ALLTRIM("|(300,62)CF8 KF15 KB0 A SP0 DR|Data types"))
 Say_fmt(ALLTRIM("|(55,56)CF8 KF15 KB0 A SP0 DR R1|0"))
 Say_fmt(ALLTRIM("|(60,333)CF10 KF0 KB8 A SP0 DR|Graph"))
 pat_setfil(1)
 fbox(95,322,235,336,0)
 font_new(nfont7)
 get_getclr(15,0,15,0,15,0)
 get_say(323,103,gr_type)
 pat_setfil(1)
 fbox(375,322,400,336,0)
 Say_fmt(ALLTRIM("|(410,333)CF10 KF0 KB8 A SP0 DR|3-D (Yes/No) -"))
 pat_setfil(1)
 fbox(485,324,495,334,0)
 fbox(486,325,494,333,15)
 Say_fmt(ALLTRIM("|(510,333)CF10 KF0 KB15 A SP0 DR|Depth -"))
 Say_fmt(ALLTRIM("|(240,333)CF8 KF0 KB15 A SP0 DR|Number  of x-axis titles"))
 Say_fmt(ALLTRIM("|(75,102)CF8 KF0 KB8 A SP0 DR|Number of legends (max.5) -"))
 Say_fmt(ALLTRIM("|(75,120)CF8 KF0 KB8 A SP0 DR|Graph title -"))
 Say_fmt(ALLTRIM("|(75,140)CF8 KF0 KB8 A SP0 DR|Graph title font-"))
 Say_fmt(ALLTRIM("|(75,160)CF8 KF0 KB8 A SP0 DR|X-axis title -"))
 Say_fmt(ALLTRIM("|(75,180)CF8 KF0 KB8 A SP0 DR|Y-axis title -"))
 Say_fmt(ALLTRIM("|(75,200)CF8 KF0 KB8 A SP0 DR|Legend titles "))
 Say_fmt(ALLTRIM("|(75,260)CF8 KF0 KB8 A SP0 DR|Legend position -"))
 Say_fmt(ALLTRIM("|(75,280)CF8 KF0 KB8 A SP0 DR|Legend colors -"))
 Say_fmt(ALLTRIM("|(75,300)CF8 KF0 KB8 A SP0 DR|X-axis title type -"))
endif
f_ans=MENU_ONLY( drop_menu2 )
          if f_ans=1
              Say_fmt(ALLTRIM("|(275,102)CF15 KF0 KB8 A SP0 DR|1"))
              leg=1
                 else
                   if f_ans=2
                      Say_fmt(ALLTRIM("|(275,102)CF15 KF0 KB8 A SP0 DR|2"))
                      leg=2
                     else
                       if f_ans=3
                          Say_fmt(ALLTRIM("|(275,102)CF15 KF0 KB8 A SP0 DR|3"))
                          leg=3
                       else
                         if f_ans=4
                           Say_fmt(ALLTRIM("|(275,102)CF15 KF0 KB8 A SP0 DR|4"))
                           leg=4
                        else
                          if f_ans=5
                            Say_fmt(ALLTRIM("|(275,102)CF15 KF0 KB8 A SP0 DR|5"))
                            leg=5
                          endif
                         endif
                       endif
                     endif
                  endif
                  do tempscr
                  FONT_NEW(nfont11)
                  get_getclr(0,8,0,8,0,8)
                  gt=get_get(108,175,gt)
                  do tempscr
return
db_mess.prg
fscreen()
cls_screen()
say_fmt(alltrim("|(150,445)CF8 KF15 KB0 A SP0 DR|(c) Semantix Computers   J.V.RAVICHANDRAN   June 1995."))
flush_evq()
tone(300,10)
pat_setfil(1)
fbox(300,300,610,400,15)
fbox(301,301,609,321,0)
pat_setfil(3)
fbox(301,322,305,399,0)
fbox(301,395,609,399,0)
fbox(605,322,609,399,0)
 say_fmt(ALLTRIM("|(425,316)CF2 KF15 KB0 A SP0 DR|GREYcells"))
 say_fmt(ALLTRIM("|(310,335)CF2 KF0 KB15 A SP0 DR|Fatal Error"))
 pat_setfil(1)
 fbox(310,338,395,341,0)
 say_fmt(ALLTRIM("|(310,365)CF2 KF0 KB15 A SP0 DR|Database(s) missing. Please contact"))
 say_fmt(ALLTRIM("|(310,385)CF2 KF0 KB15 A SP0 DR|the developer immediately."))
 say_fmt(ALLTRIM("|(308,309)CF2 KF15 KB0 A SP0 DR R1|0"))
 KEY_PRESS()
 FT='N'
 key_press()
 cls_screen()
 vm_quit()
 textmode()
 quit
Part-II

 

Hosted by www.Geocities.ws

1