
Icon arranging on desktop
I am trying to locate the methods and constants for arranging icons on
the desktop to the top, bottom, and right side.
I have code that uses an API to align the icons to the left but can't
find reference for the other constants anywhere for the other
orientations. I'm assuming that what would be required would be
defining the constants and referencing them instead of the alignleft
in the API call.
Please Cc me with email as I suspect that the mail server I use
doesn't pick up all articles. Thanks
The following code aligns icons to the left:
Private Declare Function GetWindow Lib "user32" (ByVal hwnd As Long,
ByVal wCmd As Long) As Long
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA"
(ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam
As Long) As Long
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA"
(ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Const GW_CHILD = 5
Private Const LVA_ALIGNLEFT = &H1
Private Const LVM_ARRANGE = &H1016
Dim hWnd1 As Long
Dim hWnd2 As Long
Dim Ret As Long
hWnd1 = FindWindow("Progman", vbNullString)
hWnd2 = GetWindow(hWnd1, GW_CHILD)
hWnd1 = GetWindow(hWnd2, GW_CHILD)
Ret = SendMessage(hWnd1, LVM_ARRANGE, LVA_ALIGNLEFT, 0)
Remove zzz from my email address:
~~~Golf Tip: Don't pick up a lost ball until it stops rolling~~~o
Home Page - http://www.*-*-*.com/
Standard Disclaimer (Win95 Tips, sound bites, and more!)