Results 1 to 4 of 4

Thread: [*resolved]Help me get system scrollbar's width

Threaded View

  1. #1

    Thread Starter
    l33t! MrPolite's Avatar
    Join Date
    Sep 2001
    Posts
    4,428

    Unhappy [*resolved]Help me get system scrollbar's width

    I need to find out the width of a system scroll bar (you know that this changes if you have different themes/styles on your computer).
    So for example I need to know how wide is a vertical scroll bar.I have this GetScrollInfo API, dunno if I should use it or not.
    VB Code:
    1. <StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Auto)> _
    2.     Private Structure SCROLLINFO
    3.         Public cbSize As Integer
    4.         Public fMask As Integer
    5.         Public nMin As Integer
    6.         Public nMax As Integer
    7.         Public nPage As Integer
    8.         Public nPos As Integer
    9.         Public nTrackPos As Integer
    10.     End Structure
    11.  
    12.     <DllImport("user32.dll", CharSet:=CharSet.Auto)> _
    13.     Private Function GetScrollInfo(ByVal hwnd As IntPtr, ByVal bar As Integer, ByRef si As SCROLLINFO) As Integer
    14.     End Function
    any help appriciated!
    Last edited by MrPolite; Feb 3rd, 2003 at 07:46 PM.
    rate my posts if they help ya!
    Extract thumbnail without reading the whole image file: (C# - VB)
    Apply texture to bitmaps: (C# - VB)
    Extended console library: (VB)
    Save JPEG with a certain quality (image compression): (C# - VB )
    VB.NET to C# conversion tips!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width