﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » .NET Forums » General .NET Discussion  » Could not load file or assembly '0 bytes loaded from system...Error</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Mon, 08 Jun 2026 22:44:34 GMT</lastBuildDate><ttl>20</ttl><item><title>Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25245.aspx</link><description>Hi SF Team,&lt;/P&gt;&lt;P&gt;I have a&amp;nbsp;SF application&amp;nbsp;currently&amp;nbsp;running successfully on several Vista machines.&amp;nbsp; However, on one of the Vista machines I am getting the error below.&amp;nbsp;&amp;nbsp;Can anyone tell me why&amp;nbsp;I am getting this error only on this Vista pc and not the others?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Jeff&lt;/P&gt;&lt;SPAN lang=EN&gt;&lt;P&gt;====================================================================================================================================================&lt;/P&gt;&lt;P&gt;Could not load file or assembly '0 bytes loaded from System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. An attempt was made to load a program with an incorrect format.&lt;/P&gt;&lt;P&gt;Exception (BadImageFormatException): Source="UJ.ExceptionManagement"; Target=null; Tag=null; FusionLog=""; &lt;/P&gt;&lt;P&gt;Message = "Could not load file or assembly '0 bytes loaded from System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. An attempt was made to load a program with an incorrect format."&lt;/P&gt;&lt;P&gt;InnerException (BadImageFormatException): Message="Bad IL format."; Source=null; Target=null; Tag=null; StackTrace=null; FileName=null; FusionLog=null; &lt;/P&gt;&lt;P&gt;FileName = "0 bytes loaded from System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"&lt;/P&gt;&lt;P&gt;Environment: ThreadIdentity="" DateTime=["2009-11-17 20:13:46.478"] ThreadName=null WindowsIdentity=["VistaServer\Prospect Helper"] ThreadId="1" DomainName="ProspectHelper.exe" OSVersion=["Microsoft Windows NT 6.0.6001 Service Pack 1"]&lt;/P&gt;&lt;P&gt;MachineName="VISTASERVER" UserName=["Prospect Helper"]&lt;/P&gt;&lt;P&gt;Frame0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -&lt;/P&gt;&lt;P&gt;at System.Reflection.Assembly.nLoadImage(Byte[] rawAssembly, Byte[] rawSymbolStore, Evidence evidence, StackCrawlMark&amp;amp; stackMark, Boolean fIntrospection)&lt;/P&gt;&lt;P&gt;at System.Reflection.Assembly.Load(Byte[] rawAssembly, Byte[] rawSymbolStore, Evidence securityEvidence)&lt;/P&gt;&lt;P&gt;at Microsoft.CSharp.CSharpCodeGenerator.FromFileBatch(CompilerParameters options, String[] fileNames)&lt;/P&gt;&lt;P&gt;at Microsoft.CSharp.CSharpCodeGenerator.FromSourceBatch(CompilerParameters options, String[] sources)&lt;/P&gt;&lt;P&gt;at Microsoft.CSharp.CSharpCodeGenerator.System.CodeDom.Compiler.ICodeCompiler.CompileAssemblyFromSourceBatch(CompilerParameters options, String[] sources)&lt;/P&gt;&lt;P&gt;at System.CodeDom.Compiler.CodeDomProvider.CompileAssemblyFromSource(CompilerParameters options, String[] sources)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.Native.Compiler.CompileAssemblyFromSource(CompilerParameters parameters, String source)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.Native.Compiler.GetCompiledAssembly()&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.Native.ReportCompiler.Compile(Stream stream, IServiceProvider serviceProvider, Boolean includeAppDomainReferences)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.UI.XtraReport.LoadLayoutInternal(Stream stream, XtraReport&amp;amp; source, Boolean includeAppDomainReferences, Boolean forceDataSource)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.UI.XtraReport.LoadLayout(Stream stream)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraReports.UI.XtraReport.LoadLayout(String fileName)&lt;/P&gt;&lt;P&gt;at ProspectHelper.ReportsDialog.DisplayDevExpressReport()&lt;/P&gt;&lt;P&gt;Implementer (ReportsDialog): components=System.ComponentModel.Container; ReportsBO1={ [ProspectHelper.ReportsBO]}; &lt;/P&gt;&lt;P&gt;BusinessBindingSource1 (BusinessBindingSource): Count=4; #0=ProspectHelper.ReportsBO; #1=ProspectHelper.ReportsBO; #2=ProspectHelper.ReportsBO; #3=ProspectHelper.ReportsBO; &lt;/P&gt;&lt;P&gt;scrollPosition (Point): x=0; y=0; &lt;/P&gt;&lt;P&gt;PanelControl1 (PanelControl): &lt;/P&gt;&lt;P&gt;GroupControl1 (GroupControl): LabelControl3=DevExpress.XtraEditors.LabelControl; LabelControl2=DevExpress.XtraEditors.LabelControl; dtpToDate=DevExpress.XtraEditors.DateEdit; dtpFromDate=DevExpress.XtraEditors.DateEdit;&lt;/P&gt;&lt;P&gt;LabelControl1=DevExpress.XtraEditors.LabelControl;&lt;/P&gt;&lt;P&gt;cboCampaigns = MicroFour.StrataFrame.UI.Windows.Forms.DevEx.ComboBoxEdit&lt;/P&gt;&lt;P&gt;GroupControl2 (GroupControl): btnOpenReportDesigner=DevExpress.XtraEditors.SimpleButton; btnPreviewXtraReport=DevExpress.XtraEditors.SimpleButton; btnPreview=DevExpress.XtraEditors.SimpleButton; listboxReports=DevExpress.XtraEditors.ListBoxControl; &lt;/P&gt;&lt;P&gt;Remaining Stack Trace - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -&lt;/P&gt;&lt;P&gt;at ProspectHelper.ReportsDialog.btnPreviewXtraReport_Click(Object sender, EventArgs e)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Control.OnClick(EventArgs e)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraEditors.BaseButton.OnClick(EventArgs e)&lt;/P&gt;&lt;P&gt;at DevExpress.XtraEditors.BaseButton.OnMouseUp(MouseEventArgs e)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Control.WmMouseUp(Message&amp;amp; m, MouseButtons button, Int32 clicks)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Control.WndProc(Message&amp;amp; m)&lt;/P&gt;&lt;P&gt;at DevExpress.Utils.Controls.ControlBase.WndProc(Message&amp;amp; m)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Control.ControlNative&amp;#119;indow.OnMessage(Message&amp;amp; m)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Control.ControlNative&amp;#119;indow.WndProc(Message&amp;amp; m)&lt;/P&gt;&lt;P&gt;at System.Windows.Forms.Native&amp;#119;indow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)&lt;/P&gt;&lt;/SPAN&gt;</description><pubDate>Thu, 19 Nov 2009 10:13:44 GMT</pubDate><dc:creator>Jeff Pagley</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25252.aspx</link><description>Hi Dustin,&lt;/P&gt;&lt;P&gt;The error does occur when I am trying to preview an XtraReport.&amp;nbsp; I will look into checking all of those issues you suggested.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Jeff</description><pubDate>Thu, 19 Nov 2009 10:13:44 GMT</pubDate><dc:creator>Jeff Pagley</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25251.aspx</link><description>Hi Jeff,&lt;br&gt;
&lt;br&gt;
Is this Vista OS a 64bits on AMD processor?&lt;br&gt;
&lt;br&gt;
If so, make sure your compiled project Target CPU value is setup as  "x86" instead of "AnyCPU" which is the VS default unless your application directly supports 64bits OS.&lt;br&gt;
&lt;br&gt;
You will find this option in your Project's Compile option -&gt; Advance Compile Options.</description><pubDate>Thu, 19 Nov 2009 10:05:29 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25250.aspx</link><description>Where I said "on-the-[i]file[/i] assembly compiles" I meant "on-the-[b]fly[/b] assembly compiles" :)</description><pubDate>Thu, 19 Nov 2009 08:26:31 GMT</pubDate><dc:creator>Dustin Taylor</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25249.aspx</link><description>I'm assuming ProspectHelper.exe is your app? Have you tried ensuring the environment is the same as the other machines? DEP, Firewalls, etc. are set to match?&lt;/P&gt;&lt;P&gt;I've also seen active antivirus mess with those on-the-file assembly compiles, which could be part of the problem. In our own app, certain active anti-viruses will delete the run-time complied script .DLLs that PerpetuumSoft generates when printing reports. If XtraReports does something similar, it could be a similar issue.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Try stripping off everything along those lines: AntiVirus, Firewall, Spyware, DEP, UAC, basically anything that will try and interfere with your environment "for your own protection" and see if you have better results.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Past that, I would agree with Greg that it sounds like a corrupted file hanging out there. The stack trace makes it sound like it is trying to pull an image out of a dynamically generated assembly, but if I'm misreading that and it is actually trying to pull out of a static assembly, you'll need to figure out which one and identify the bad copy.</description><pubDate>Thu, 19 Nov 2009 08:24:03 GMT</pubDate><dc:creator>Dustin Taylor</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25248.aspx</link><description>Yes I did try a reinstall, but I got the same error.</description><pubDate>Wed, 18 Nov 2009 20:56:30 GMT</pubDate><dc:creator>Jeff Pagley</dc:creator></item><item><title>RE: Could not load file or assembly '0 bytes loaded from system...Error</title><link>http://forum.strataframe.net/FindPost25246.aspx</link><description>You've probably tried this, but it seems like the file is corrupt (or maybe the HD is dying), so did you try a reinstall?</description><pubDate>Wed, 18 Nov 2009 19:43:30 GMT</pubDate><dc:creator>Greg McGuffey</dc:creator></item></channel></rss>