qb45advr.hlp (Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
.krsetx
:nRSET Statement Programming Example
  QuickSCREEN      Details     Example      Contents      Index
──────────────────────────────────────────────────────────────────────────────
RSET Statement Programming Example
 
This example shows the effects of using RSET to assign values to
fixed- and variable-length strings.
 
DIM TmpStr2 AS STRING * 10
CLS    ' Clear screen
PRINT "         1         2         3"
PRINT "123456789012345678901234567890"
' Use RSET on null variable-length string of length.
' Nothing prints because TmpStr$ is a zero-length field.
TmpStr$ = ""
RSET TmpStr$ = "Another"
PRINT TmpStr$
' Use RSET on variable-length string with a value.
TmpStr$ = SPACE$(20)
RSET TmpStr$ = "Another"
PRINT TmpStr$
' Use RSET on fixed-length string of length 10.
RSET TmpStr2 = "Another"
PRINT TmpStr2
 
Sample Output
 
         1         2         3
123456789012345678901234567890
 
             Another
   Another