home *** CD-ROM | disk | FTP | other *** search
/ HTBasic 9.3 / HTBasic 9.3.iso / 93win / data1.cab / Basic_Plus_Examples / ERRDIAL < prev    next >
Encoding:
Text File  |  2005-03-02  |  968 b   |  25 lines

  1. 10    ! ***************************************************
  2. 20    ! Example: ERROR Dialog
  3. 30    !
  4. 40    ! This program creates an ERROR dialog. If the user selects
  5. 50    ! a button (ABORT or CONTINE) within 10 seconds, the program
  6. 60    ! displays the choice. If the user does not make a choice
  7. 70    ! within 10 seconds, "Timeout occurred - no entry" is displayed.
  8. 80    !
  9. 90    ! ****************************************************
  10. 100    !
  11. 110       DIM T$[16],P$[40],A1$[20],S1$(1:2)[10],A2$[20]
  12. 120       INTEGER Btn
  13. 130       DATA "ERROR","Input caused overflow  "
  14. 140       READ T$,P$
  15. 150       DATA "DIALOG BUTTONS","ABORT","CONTINUE","DEFAULT BUTTON"
  16. 160       READ A1$,S1$(*),A2$
  17. 170    !
  18. 180       DIALOG T$,P$,Btn;SET ("TITLE":" Example: ERROR Dialog",A1$:S1$(*),A2$:0),TIMEOUT 10
  19. 190       IF Btn=-1 THEN
  20. 200           DISP "Timeout occurred - no entry"
  21. 210       ELSE
  22. 220           DISP S1$(Btn+1)
  23. 230       END IF
  24. 240       END
  25.