home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 18 REXX / 18-REXX.zip / vxtech06.zip / VXTECH06 / EMPLIST / WINPOS.VRX < prev   
Text File  |  1994-04-25  |  628b  |  33 lines

  1. /*:VRX         Main
  2. */
  3. Main:
  4.     parse arg hWnd, hPos, vPos
  5.  
  6.     sHeight = VRGet( "Screen", "Height" )
  7.     sWidth = VRGet( "Screen", "Width" )
  8.  
  9.     height = trunc( sHeight/2  )
  10.     width = trunc( sWidth/2  )
  11.  
  12.     height = Max( height, 6000 )
  13.     width = Max( width, 6000 )
  14.  
  15.     if Translate( hPos ) = "TOP" then do
  16.         top = 0
  17.     end
  18.     else do
  19.         top = sHeight - height
  20.     end
  21.  
  22.     if Translate( vPos ) = "LEFT" then do
  23.         left = 0
  24.     end
  25.     else do
  26.         left = sWidth - width
  27.     end
  28.  
  29.     call VRSet hWnd, "Left", left, "Top", top, "Height", height, "Width", width
  30.  
  31. exit
  32.  
  33.