Rick Brewster Posted October 11, 2005 Share Posted October 11, 2005 Until Beta 4 is released, here is how to fix the problem where Paint.NET crashes when trying to save a TGA image. (solution originally posted here: http://paintdotnet.12.forumer.com/viewtopic.php?t=375) Simply go to the command line (Start -> Run, type "cmd" and click OK) and type the following: %WINDIR%\Microsoft.Net\Framework\v1.1.4322\gacutil.exe /u TgaFileType You should see output similar to the following: Microsoft (R) .NET Global Assembly Cache Utility. Version 1.1.4318.0 Copyright (C) Microsoft Corporation 1998-2002. All rights reserved. Assembly: TgaFileType, Version=2.5.2108.39008, Culture=neutral, PublicKeyToken=85cad16301864386, Cus tom=null Uninstalled: TgaFileType, Version=2.5.2108.39008, Culture=neutral, PublicKeyToken=85cad16301864386, Custom=null Number of items uninstalled = 1 Number of failures = 0 I have a "real" fix for this, but it won't be available until Beta 4 is released. Thanks for your patience everyone! Very verbose explanation of the bug (for those who are curious): Interestingly, the code for saving/loading a TGA image hasn't even changed in Beta 3 and is not the culprit for this crash. We have started to strong-name* our assemblies with this latest release and there seems to have been a version mismatch in the way that the file format configuration settings were being saved and loaded. Because of the move to strong-naming, we had to update our code that locates the assembly that can handle loading the file type settings. Unfortunately, we didn't realize this until after Beta 3 was published. Basically we weren't providing enough information for .NET to be able to locate and load the assembly correctly, and the fix above removes the TGA code from the GAC and lets .NET load things using "the old way." * "Strong-naming" is a way to give an assembly (DLL) something of a more fully qualified name, or identity. Normally you might write code saying, "load the assembly called DataStorage.dll" and the system will look in the current directory, and then in the system directory, for the file. With strong naming you specify the name, the version, and a public-key token (it's like a signature). Now you say "load the assembly called DataStorage, Version=126.96.36.199, PublicKey token=1234abcd5678efab". This forms a strong identity for the assembly. For example, if I release version 188.8.131.52 of DataStorage, then all the old code that still wants to use 184.108.40.206 is still able to do so. This is very important on servers so that applications that are deployed and working great don't get their dependencies updated with new features (and new bugs) that change the way things work. Also, if someone else publishes an assembly called "DataStorage", their PublicKey token will be different, and thus the correct assembly will still be loaded. Quote The Paint.NET Blog: https://blog.getpaint.net/ Donations are always appreciated! https://www.getpaint.net/donate.html Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.