Using Windows 7 powrprof.dll on Windows XP

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bage
    New Member
    • Dec 2009
    • 1

    Using Windows 7 powrprof.dll on Windows XP

    Hi all,

    I had an application which linked with Win7's powrprof.dll.
    However, when I ran it on WinXP, it arised a error message box which telling me it's unable to find _except_handler 4_common in msvcrt.dll.

    I found that Win7's powrprof.dll is statically linked with Win7's msvcrt.dll, but on WinXP, msvcrt.dll didn't have _except_handler 4_common symbol.

    Since my application needs to be run both on WinXP/Win7 and functions I called were located in Win7's powrprof.dll. What can I do now? Is there any solution?

    Thanks for your attention.

    WT
  • RedSon
    Recognized Expert Expert
    • Jan 2007
    • 4980

    #2
    You will have to write and compile your application to work for both Win7 and Windows XP. You should be able to define an environment variable that will tell you application to run in one mode or another after you have compiled it.

    You can download the Windows 7 SDK and install it on you XP machine and run your application from Visual Studio to confirm that it works.

    But replacing system level libraries on your XP machine from a Win7 machine is a very bad idea.

    Comment

    Working...