Error Reading Icon The Data Is Invalid
Contents |
here for a quick overview of the site Help Center Detailed answers to any
Error Generating Win32 Resource Error Reading Icon
questions you might have Meta Discuss the workings and policies of error creating win32 resources error reading icon this site About Us Learn more about Stack Overflow the company Business Learn more about
Invalid Data Error Reading Pass
hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow error building win32 resources -- icon stream is not in the expected format. is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Invalid Resource File up vote 8 down vote favorite 2 When attempting to compile my C# project, I get the following error: 'C:\Documents and Settings\Dan\Desktop\Rowdy Pixel\Apps\CleanerMenu\CleanerMenu\obj\Debug\CSC97.tmp' is not a valid Win32 error generating win32 resource access is denied resource file. Having gone through many Google searches, I have determined that this is usually caused by a 256x256 image inside an icon used by the project. I've gone through all the icons and removed the 256x256 versions, but the error persists. Any ideas on how to get rid of this? @Mike: It showed up mysteriously one night. I've searched the csproj file, but there's no mention of a CSC97.tmp (I also checked the solution file, but I had no luck there either). In case it helps, I've posted the contents of the csproj file on pastebin. @Derek: No problem. Here's the compiler output. ------ Build started: Project: Infralution.Licensing, Configuration: Debug Any CPU ------ Infralution.Licensing -> C:\Documents and Settings\Dan\Desktop\Rowdy Pixel\Apps\CleanerMenu\Infralution.Licensing\bin\Debug\Infralution.Licensing.dll ------ Build started: Project: CleanerMenu, Configuration: Debug Any CPU ------ C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Csc.exe /noconfig /nowarn:1701,1702 /errorreport:prompt /warn:4 /define:DEBUG;TRACE /main:CleanerMenu.Program /reference:"C:\Documents and Settings\Dan\Desktop\Rowdy Pixel\Apps\CleanerMenu\Infralution.Licensing\bin\Debug\Infralution.Licensing.dll" /reference:..\NotificationBar.dll /reference:..\PSTaskDialog.dll /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Data.dll /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Windows.Forms.dll /reference:C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /reference:obj\Debug\Interop.IWshRuntimeLibrary.dll /debug+ /debug:full /optimize- /out:obj\Debug\CleanerMenu.exe /resource:obj\Debug\CleanerMenu.Form1.resources /
resources Windows Server 2012 resources Programs MSDN subscriptions Overview Benefits Administrators Students Microsoft Imagine Microsoft Student Partners ISV Startups TechRewards Events Community Magazine Forums Blogs Channel 9 Documentation APIs and reference
Icon Editor
Dev centers Retired content Samples We’re sorry. The content you requested has convert png to ico been removed. You’ll be auto redirected in 1 second. Integrated Development Environment for Visual Studio Deploying Applications and Components Deployment Error Messages Deployment Error Messages Invalid icon file Invalid icon file Invalid icon file .NET Framework launch condition '
Express editions) > .NET General > Error in Setting an Icon to My Project Thread Tools Display Modes #1 03-08-2007, 03:12 PM cgi_pro Regular Join Date: Dec 2006 Posts: 74 Error in Setting an Icon to My Project Hello I right-clicked http://www.xtremevbtalk.com/-net-general/280735-error-setting-icon-project.html on the project name of mine and set the icon in the common property to some (MyIcon.ico) that resides somewhere on my PC. When I ran the application, I got the following error message: Error creating ALink Win32 resources: Error reading icon 'C:\[PATH TO MY ICON IMAGE]\myicon.ico' -- The data is invalid. I discovered that I need to have my icon in the same directory of my project. If this is the case that will solve my problem then it's not how I want it, because error reading this application I'm building needs to have ONLY its executable file distributed to my application users. So how can I let this icon be part of the compiled executable file? cgi_pro View Public Profile Find all posts by cgi_pro #2 03-08-2007, 04:09 PM Eduardo Lorenzo Senior Contributor Join Date: Jun 2006 Location: Manila, Philippines Posts: 846 well the Icon should be embedded within the exe file at creation so there really is nothing you can do about it. and you will still error reading icon be sending out ONLY the exe file. __________________ Pinoy ako.. ipinagmamalaki ko. Eduardo Lorenzo View Public Profile Find all posts by Eduardo Lorenzo #3 03-09-2007, 12:32 AM cgi_pro Regular Join Date: Dec 2006 Posts: 74 That what I actually want. I want the icon to be embedded within the exe file so that when I give the application (the exe file) to the user, I don't have to give him the icon file along with it in irder for the icon to show with the application. My problem once again is this: I have an icon image (*.ico file) inside the folder of my project. I want to set this icon to be my project icon. So what I have to do is o right-click on my project name (within my Solution Explorer Window) and go to properties. In properties dialog box I go to (Common Properties -> Build -> Application Icon) to set that icon to my application. Finally when I compile, I receive the following error message: Error creating ALink Win32 resources: Error reading icon 'C:\[SOME_PATH]\myicon.ico' -- The data is invalid. What's wrong in my steps in setting this application icon? cgi_pro View Public Profile Find all posts by cgi_pro #4 03-09-2007, 12:40 AM Eduardo Lorenzo Senior Contributor Join Date: Jun 2006 Location: Manila, Philippines Posts: 846 I am using here VS 2005 In the IDE, I click on the form and set the icon in the PRoperties Explorer then I right-click the solution and choose Proper