home *** CD-ROM | disk | FTP | other *** search
- /* This is a dummy script doing nothing meaningfull except for
- demonstration of the GETATTR command
- Hasse Wehner, Mermaid Group
- */
- options results
- trace off
- address twist
- dbfilename = "TWIST:TestGetAttr2"
- open dbfilename
- if RC!=0 then
- do
- say dbfilename
- CREATEDB dbfilename
- if RC!=0 then exit 1
- CREATEFIELD "Name"
- if RC!=0 then exit 2
- CREATEFIELD "Address"
- if RC!=0 then exit 3
- ENDCREATEDB
- if RC!=0 then exit 4
- open dbfilename
- end
- if RC~=0 then
- do
- say "unable to open " dbfilename
- exit
- end
-
-
- GETATTR APPLICATION VERSION
- say result
-
-
- OPENWINDOW
-
- GETATTR WINDOW DIMS STEM DBWINDIM
- SAY DBWINDIM.MIN.WIDTH
- SAY DBWINDIM.MIN.HEIGHT
-
- "GETATTR FIELD ADDRESS"
- SAY RESULT
-
-
- "GETATTR FIELDS STEM FLDS"
- say FLDS.COUNT
- do i=0 to FLDS.COUNT-1
- "GETATTR FIELD" FLDS.i "VAR FIELDATTR"
- say FIELDATTR
- end
- CLOSEWINDOW
- CLOSE
-