How to ship gdiplus.dll but not have Windows use it?

孤者浪人 提交于 2019-12-23 05:37:10

问题


i have an application that has a dependancy on gdiplus. i need the application to also run on Windows 2000.

i want to include GDIPlus in the application directory, so that Windows 2000 computers will function, but if the machine is Windows XP, Windows Vista, Windows 7, etc, i want it to use the version of GDIPlus that ships, and is updated, with Windows.

Not possible?


回答1:


From http://msdn.microsoft.com/en-us/library/ms997620.aspx Try adding the following to your manifest :-

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <assemblyIdentity version="1.0.0.0" processorArchitecture="x86"
         name="Microsoft.Windows.mysampleapp" type="win32" />
    <description>Your app description here</description>
    <dependency>
        <dependentAssembly>
            <assemblyIdentity type="win32" name="Microsoft.Windows.GdiPlus"
                version="1.0.0.0" processorArchitecture="x86"
                publicKeyToken="6595b64144ccf1df" language="*" />
        </dependentAssembly>
    </dependency>
</assembly>



回答2:


Won't it be easier to do it from the installer ? IF you are installing on Windows 2000 copy Gdiplus to application directory otherwise skip it.




回答3:


From the GDI+ page:

Run-time Requirements

Gdiplus.dll is included with Windows XP. For information about which operating systems are required to use a particular class or method, see the More Information section of the documentation for the class or method. GDI+ is available as a redistributable for Windows NT 4.0 SP6, Windows 2000, Windows 98, and Windows Me. To download the latest redistributable, see http://www.microsoft.com/msdownload/platformsdk/sdkupdate/psdkredist.htm.

First hit on Google for "win2000 gdiplus".



来源:https://stackoverflow.com/questions/981125/how-to-ship-gdiplus-dll-but-not-have-windows-use-it

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!