     Exit Sub
   End If
      
   ' Determine which scroll bars we have:
   Dim lStyle As Long
   lStyle = GetWindowLong(hwnd, GWL_STYLE)
   m_bHasHorizontalScroll = ((lStyle And WS_HSCROLL) = WS_HSCROLL)
   m_bHasVerticalScroll = ((lStyle And WS_VSCROLL) = WS_VSCROLL)
   Dim tSBI As SCROLLBARINFO
   tSBI.cbSize = Len(tSBI)
   GetScrollBarInfo hwnd, OBJID_HSCROLL, tSBI
   If (tSBI.rgstate(0) And STATE_SYSTEM_UNAVAILABLE) = STATE_SYSTEM_UNAVAILABLE
    Then
      m_bHasHorizontalScroll = False
   End If
   G