Carlo, could be that version of Windows didn't have SHLWAPI.DLL built in.
You could also look for it in Windows Explorer. Perhaps it is somewhere on
your system that is not in the path so it just isn't being found. You may
Windows that didn't have already installed.
Dear David, thanks for your attention.
We are on the way to reproduce the problem, setting up NT4 on a virtual
machine.
Surely, using VC6 we had no problem.
Ok, now i tried...
Our application give the message regarding GetLongPathNameW.
So i tried to build a dummy MFC application setting the flags (pasted from
BuildLog.html)
/O2 /GL /D "WIN32" /D "_WINDOWS" /D "NDEBUG" /D "_WIN32_WINNT=0x0400" /D
"WINVER=0x0400" /FD /EHsc /MT /Yu"stdafx.h" /Fp"Release\mfc8_on_nt4.pch"
/Fo"Release\\" /Fd"Release\vc80.pdb" /W3 /c /Wp64 /Zi /TP
.\mfc8_on_nt4View.cpp
I changed the [general] setting to use use MFC in a static library, to
simplify the problem, altough out application uses MFC extensions DLLs.
Launching the application i get a different error: (i translate from
italian, it's not the exact message):
can't locate the DLL 'SHLWAPI.DLL'.
If i recompile using MFC in a shared library, i get (in buildlog.html)
/O2 /GL /D "WIN32" /D "_WINDOWS" /D "NDEBUG" /D "_WIN32_WINNT=0x0400" /D
"WINVER=0x0400" /D "_AFXDLL" /FD /EHsc /MD /Yu"stdafx.h"
/Fp"Release\mfc8_on_nt4.pch" /Fo"Release\\" /Fd"Release\vc80.pdb" /W3 /c
/Wp64 /Zi /TP .\mfc8_on_nt4View.cpp
and the runtime error relative to GetLongPathNameW.
Do you know some workaround?
Many thanks again...
Bye Carlo
"David Wilkinson" <no-reply@effisols.com> ha scritto nel messaggio
news:%238Z94C8kHHA.3484@TK2MSFTNGP02.phx.gbl...
Carlo Capelli wrote:
I got a problem releasing our application, recompiled with visualstudio
2005.
Some user still using NT4 reports an exception like 'could not find
entry
point for GetLongPathNameW in kernel32.dll'.
I think it's related to MFC8 compilation: it's NT4 unsupported? Or
maybe
a
patch is required?
Many thanks in advance.
Carlo:
These are the minimum supported target platforms for the different VS
versions:
VC5: Windows 95 and Windows NT4
VC6: Windows 95 and Windows NT4
VS2002: Windows 98 and Windows 2000
VS2003: Windows 98 and Windows 2000
VS2005: Windows 98 and Windows 2000
Orcas: Windows 2000
However, this does not necessarily mean that a particular application
will not run on an earlier system than that indicated. If you want to
support Windows 95/NT then you should define WINVER to be 0x0400; this
"should" catch unsupported features at compile time.
If you look at the documentation for GetLongPathName() you will see it
requires Windows 98 or Windows 2000. Kernel32.dll is part of the OS, and
the NT4 version apparently does not contain GetLongPathName(). You will
have to get rid of this call.
Are you sure that your code worked on NT4 with an earlier version of the
compiler? This does not seem possible.
--
David Wilkinson
Visual C++ MVP