This program displays a Dictionary-IV view from Basic. It fills in VIEW$ with the view name, sort number, cursor mode and change switches, then calls OO3A, the method behind CONNECT VIEW.

! Example of using CONNECT VIEW from a Basic program
! This example uses the sample data that is sent out with Idol-IV
! This sample data is in library UT
!
00010 REM &REM&
00100 CALL "IDPUB4",]6$,]7$,]8$,]9$ ! Set Idol-IV System Variables
00110 CALL "8ZPSYS",]SYSV$ !
00120 DIM VIEW$[17] ! Dimension SCREEN$ for call
00130 LET VIEW$[1] = "IAVCUST", ! Screen Name
VIEW$[3] = "3", ! Sort Number
VIEW$[8] = "IAVCUST", ! View Name
VIEW$[9] = "E", ! Cursor Mode - Entire Field
VIEW$[10] = "F", ! Carriage Return - Field Edit
VIEW$[13] = "Y" + ! Switchs - Change Key
"Y" + ! Change Data
"Y" + ! Change View
"N" + ! Leave View Displayed
"Y" ! Change Sort
00140 CALL "OO3A",VIEW$[ALL] ! Call CONNECT SCREEN
00200 END

Notes

  • The example uses view IAVCUST from the UT sample library that ships with IDOL-IV.
  • Some comments in the code mention SCREEN$, a screen name and CONNECT SCREEN. They were carried over from the screen example: the program uses VIEW$ and calls OO3A, which runs CONNECT VIEW.

Search tbred.com