home *** CD-ROM | disk | FTP | other *** search
/ Shareware Overload / ShartewareOverload.cdr / progm / baslib1.zip / GETPUT.BAS < prev    next >
BASIC Source File  |  1987-03-27  |  1KB  |  56 lines

  1. 'Demo of GET & PUT statements
  2. 'By John Craig, Jeff Bretz
  3. 'Other rwts & conversion to quickbasic 2.01 by Dennis Dreyer
  4. 'GETPUT.BAS
  5.  
  6. locate 9,30:Print    "                    "
  7. locate 10,30,0:Print "   A GET/PUT DEMO   "
  8. locate 11,30:Print " In Quickbasic 2.01 "
  9. locate 12,30:Print    "                    "
  10. color 4,4,1:locate 13,30:Print "                    "
  11. locate 8,30:Print "                    "
  12. locate 20,22:color 4,0:Print " To Quit after DEMO press any key!"
  13. for w=1 to 10000:next
  14.  
  15. clear:screen 1,1
  16. color 6,1:cls
  17. dim shared A(900),B(900):'Arrays to store sections of screen
  18.  
  19. for radius=21 to 147 step 21
  20. circle (160,100),radius,,,,.6
  21. paint (158+radius,100),radius mod 4,3     '{Graphics drawing rwts
  22. next radius
  23.  
  24. 'Get the area stored into arrays
  25. get (30,50)-(130,100),A
  26. get (190,100)-(290,150),B
  27.  
  28. while inkey$=""
  29.  
  30. 'Glue arrays back in switched position
  31. put (30,50),b,pset
  32. put (190,100),A,pset
  33.  
  34. CALL DELAYSECOND
  35.  
  36. 'Glue them back in original positions
  37. put (30,50),a,pset
  38. put (190,100),b,pset
  39.  
  40. CALL DELAYSECOND
  41.  
  42. wend
  43. cls:end
  44.  
  45. SUB DELAYSECOND STATIC
  46. delay=1
  47. delay.seconds=delay
  48. while delay.seconds
  49. temporary$=time$
  50. while time$=temporary$
  51. wend
  52. delay.seconds=delay.seconds -1
  53. wend
  54.  
  55. end sub
  56.