shlwapi.dll



According to the info I found at MSFT's web site.

PathIsLFNFileSpec requires version 5.0, or later, of shlwapi.dll, with a
minimum of Windows 95 with IE 5
PathFileExists requires version 4.71, or later, of shlwapi.dll, with a
minimum of Windows 95 with IE 4

My Win 95 system has version 5.00.2919.6304 of shlwapi.dll and version
5.00.2919.6307 of IE.

But, running the code below indicates that neither API function is present.
What's amiss?

Option Explicit
Private Declare Function GetModuleHandle Lib "kernel32.dll" Alias
"GetModuleHandleA" _
(ByVal lpModuleName As String) As Long
Private Declare Function GetProcAddress Lib "kernel32" _
(ByVal hModule As Long, ByVal lpProcName As String) As Long

Private Sub Form_Load()
Me.AutoRedraw = True
If GetProcAddress(GetModuleHandle("shlwapi.dll"), "PathIsLFNFileSpecA")
= 0 Then
Me.Print "Missing PathIsLFNFileSpecA"
Else
Me.Print "Found PathIsLFNFileSpecA"
End If

If GetProcAddress(GetModuleHandle("shlwapi.dll"), "PathFileExistsA") = 0
Then
Me.Print "Missing PathFileExistsA"
Else
Me.Print "Found PathFileExistsA"
End If

If GetProcAddress(GetModuleHandle("kernel32.dll"),
"GetDiskFreeSpaceExA") = 0 Then
Me.Print "Missing GetDiskFreeSpaceExA"
Else
Me.Print "Found GetDiskFreeSpaceExA"
End If

If GetProcAddress(GetModuleHandle("kernel32.dll"), "GetDiskFreeSpaceA")
= 0 Then
Me.Print "Missing GetDiskFreeSpaceA"
Else
Me.Print "Found GetDiskFreeSpaceA"
End If
End Sub

--
http://www.standards.com/; See Howard Kaikow's web site.


.



Relevant Pages

  • Re: Windows apperance
    ... Private Declare Function IsThemeActive Lib "uxtheme.dll" As Boolean ... Private Sub Command1_Click ... > How I can detect witch windows style is used ...
    (microsoft.public.vb.winapi.graphics)
  • Re: Writing to file - CPU usage
    ... I'm sure you're already aware that Windows is a multitasking ... case you can ask Windows to give your own process a lower priority. ... Private Declare Function SetThreadPriority _ ... Private Sub Form_Load ...
    (microsoft.public.vb.general.discussion)
  • Re: Are VBA userforms always child of Windows desktop?
    ... I know just enough about Windows hierarchy/relationships to thorough ... A quick look with Spy++ shows the owner and parent of a modeless ... Private Declare Function GetParent Lib "user32" As ... Private Sub UserForm_Activate ...
    (microsoft.public.excel.programming)
  • Re: Problem with SavePicture, and a question on new versions
    ... Windows API routines. ... You'll need to add a picture box to your Form (Picture1 in this ... Private Declare Function GetDC Lib "user32" _ ... Private Sub Command1_Click ...
    (comp.lang.basic.visual.misc)
  • [NT] Vulnerability in HTML Help Allows Code Execution (MS05-001)
    ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... Get your security news from a reliable source. ... * Microsoft Windows XP Service Pack 1 and Microsoft Windows XP Service ...
    (Securiteam)

Loading