Results 1 to 2 of 2

Thread: Testing

  1. #1
    Megatron
    Guest

    Testing

    testing, don't reply
    VB Code:
    1. Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Long, ByVal lpString As String, ByVal cch As Long) As Long
    2. Declare Function GetWindowTextLength Lib "user32" Alias "GetWindowTextLengthA" (ByVal hwnd As Long) As Long
    3. Declare Function EnumWindows Lib "user32.dll" (ByVal lpEnumFunc As Long, ByVal lParam As Long) As Long
    4.  
    5. Public Function EnumWindowsProc(ByVal hwnd As Long, ByVal lParam As Long) As Long
    6.     Dim Length As Long
    7.     Dim sName As String
    8.     Dim Temp As String
    9.     Static iCount As Integer
    10.    
    11.     iCount = iCount + 1
    12.     Length = GetWindowTextLength(hwnd) + 1
    13.    
    14.     If Length > 1 Then
    15.       sName = Space(Length)
    16.       GetWindowText hwnd, sName, Length
    17.       Debug.Print Left(sName, Length - 1)
    18.     End If
    19.    
    20.     EnumWindowsProc = 1
    21. End Function

  2. #2
    Matthew Gates
    Guest
    Just what the doctor asked for, see that Megatron, always knew John would get to the color coding .

    It doesn't have to many bugs.

    Except maybe Object.Left / Object.Right.

    VB Code:
    1. Object.Left
    2. Object.Right



    Wonder if you can stop color coding in the vbcode tag.


    VB Code:
    1. Object.[/color]Left
    2. Object.[/color]Right

    VB Code:
    1. Object.[color=black]Left
    2. Object.[color=black]Right
    3.  
    4. Object.[color=black]Left[/color]
    5. Object.[color=black]Right[/color]

    Eh, oh well .

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