[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
VS_ScrlBar()         Calculate light bar position

Description:

  VS_ScrlBar() calculates the light bar position for "procedure meters"
  such as VS_ShowNtx(), etc.

Syntax:     

  n_BarLine = VS_ScrlBar( n_RelPos, n_Blocks, n_Elements )

Pass:       

  n_RelPos is a numeric value that represents the relativ position
  win the list (eg which line are we on?, how fr along is procedure?,
  etc.)

  n_Blocks is a numeric value that represents how many blocks are
  the scroll bar(don't include the up/down pointers if youe them)

  n_Elements is a numeric value that represents how many total
  lements (enes within a list, records within a dbf, etc)

Return:     

  n_BarLine is a numeric value that represents which line to draw
  the "high-light" marker on.

Notes:      


Example:    

  @ 10,25 SAY REPLICATE("#",50)
  @ 11,25 SAY VS_PadStr("Percentage Complete",50)

  GO TOP
  DO WHILE .NOT. EOF()

     @ 10,25 SAY REPLICATE("#", VS_ScrlBar(RECNO(),50,RECCOUNT()) )

     DO SomeProcs
     ...

     SKIP

  ENDDO

Usage:      

  VS_ScrlBar() is used within VERNSIX.LIB in several locations to show
  the user what the status of an operation is, and to show positions
  within a list, etc.

  Carefully study ACHOICE() and TBROWSE() and you will see unlimited
  potential for VS_ScrlBar()

See Also:
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson