Question:
Attempt to use custom iconfile for self extracting zip file fails in c#. See below for LastErrorText contents. I have tried many different .ico files with the same result. The same .ico that fails with my c# ZIP code works using ChilkatZipSE however ChilkatZipSE bombs with large files. I am following the procedures listed at link text but still cannot get the custom icon to work. Do you see anything in the error output that might indicate the problem?
LastErrorText
ChilkatLog:
WriteExe:
DllDate: Aug 3 2011
UnlockPrefix: MyUnlockCode
Username: MyUserName
Architecture: Little Endian; 64-bit
Language: .NET 4.0 / x64
SfxRuntimeSize: 475136
tempFile1: .\ckExe_ZFGL.dat
rva is NULL
Failed to build resource tree..
Failed to load EXE image.
Proceeding without custom icon...
<SfxConfig>
<AutoTemp>1</AutoTemp>
<DeleteAfterSetup>0</DeleteAfterSetup>
<ShowFin>0</ShowFin>
<ShowMain>0</ShowMain>
<ShowProgress>0</ShowProgress>
<WaitForSetup>1</WaitForSetup>
<Encryption>0</Encryption>
<KeyLength>128</KeyLength>
<MainTitle>Archive Utility</MainTitle>
<DefaultDir />
<Cleanup>1</Cleanup>
<ProgressTitle>Extracting</ProgressTitle>
<ProgressCaption>Extracting setup files . . .</ProgressCaption>
<SetupExe>setup.exe</SetupExe>
<IconFile>c:\myicon.ico</IconFile>
<VersionCreatedBy>14.4.0</VersionCreatedBy>
</SfxConfig>
First thing I notice is that you are using a very old version of the library (from 2011). I recommend trying again with the latest version of Chilkat to see if there's an issue that been fixed already. If the problem persists, please post the contents of the LastErrorText property from the latest version in case there is new information in the log.
That was one of the things I had tried also but it still did not work, here is the LastErrorText using the latest DLL. Just to clarify further the self extracting zip is created just fine, it is just the icon file that is not working
ChilkatLog:
WriteExe(219ms):
DllDate: Dec 29 2015
ChilkatVersion: 9.5.0.55
UnlockPrefix: MyUnlockCode
Username: MyUserName
Architecture: Little Endian; 64-bit
Language: .NET 4.5 / x64
VerboseLogging: 1
writeExeToOutput(219ms):
SfxRuntimeSize: 409600
tempFile1: .\ckExe_0JSZ.dat
rva is NULL
Failed to build resource tree..
Failed to load EXE image.
Proceeding without custom icon...
writeExeToOutput2(203ms):
<SfxConfig>
<AutoTemp>1</AutoTemp>
<DeleteAfterSetup>0</DeleteAfterSetup>
<ShowFin>0</ShowFin>
<ShowMain>0</ShowMain>
<ShowProgress>1</ShowProgress>
<WaitForSetup>1</WaitForSetup>
<Encryption>0</Encryption>
<KeyLength>128</KeyLength>
<MainTitle>Archive Utility</MainTitle>
<DefaultDir />
<Cleanup>1</Cleanup>
<ProgressTitle>UPS</ProgressTitle>
<ProgressCaption>Extracting</ProgressCaption>
<SetupExe>setup.exe</SetupExe>
<IconFile>c:\myicon.ico</IconFile>
<VersionCreatedBy>15.0.0</VersionCreatedBy>
</SfxConfig>
Hi, same problem for me with the 9.5.0.58 :
thanks for help
Thomas
Unfortunately, the ExeIconFile property is only possible w/ 32-bit applications. There's no possible way to make this work in a 64-bit application. Assuming you are using .NET (C# or VB.NET), then check the "Prefer 32-bit" checkbox in your Project Settings, or specifically target your application for 32-bit (instead of Any CPU).
I'll make a note in the online reference documentation for the 32-bit restriction for ExeIconFile.