User Tools

Site Tools


prop_hscrollpos.htm
Navigation:  Language Reference > App C - PROP: Runtime Properties > Complete Property List >====== PROP:HscrollPos ====== Previous pageReturn to chapter overviewNext page

Returns the position of the horizontal scroll bar's “thumb” (from 0 to 255) on a window, IMAGE, TEXT, LIST or COMBO with the HSCROLL attribute. Setting this causes the control or window's contents to scroll horizontally.

Example:

Que     QUEUE

F1      STRING(50)

F2      STRING(50)

F3      STRING(50)

     END

WinView   WINDOW('View'),AT(,,340,200),SYSTEM,CENTER

      LIST,AT(20,0,300,200),USE(?List),FROM(Que),IMM,HVSCROLL  |

        FORMAT('80L#1#80L#2#80L#3#')

     END

CODE

OPEN(WinView)

DO BuildListQue

ACCEPT

 CASE FIELD()

 OF ?List

  CASE EVENT()

  OF EVENT:ScrollDrag

   CASE (?List{PROP:HscrollPos} % 200) + 1

   OF 1

    ?List{PROP:Format} = '80L#1#80L#2#80L#3#'

   OF 2

    ?List{PROP:Format} = '80L#2#80L#3#80L#1#'

   OF 3

    ?List{PROP:Format} = '80L#3#80L#1#80L#2#'

   END

   DISPLAY  

. . .

FREE(Que)

BuildListQue  ROUTINE

LOOP 15 TIMES

 Que.F1 = 'F1F1F1F1'

 Que.F2 = 'F2F2F2F2'

 Que.F3 = 'F3F3F3F3'

 ADD(Que)

END

prop_hscrollpos.htm.txt · Last modified: 2021/04/15 15:57 (external edit)