Dim FileName AsString = System.IO.Path.GetFileName(FileUploadBenGrid.PostedFile.FileName)
Dim FilePath AsString = System.IO.Path.GetFullPath((FileUploadBenGrid.PostedFile.FileName))
'Read file into a stream
Dim fs As FileStream = New FileStream(FilePath, FileMode.Open, FileAccess.Read)
Dim br As BinaryReader = New BinaryReader(fs)
Dim bytes AsByte() = br.ReadBytes(Convert.ToInt32(fs.Length))
Select a file to upload
I'm hoping someone here can help me. I have been asked by a business unit in my company to find the cause of why a dotNet program cannot run on a certain Dell model laptop. It runs fine on a newly image laptop of all different Dell model of laptops and desktop, but for some reason on a Dell M8600 it fails to open. The M8600 has the same .Net 4.5.2 install. Could there be a missing driver that is needed to load a dotNet executable?
I'm sorry if any of my statements don't make sense. I'm not a programmer or scripter. So I am way out of my comfort zone here. I am completely loss as what could be the reason why the program is failing on a particular model of laptop.
I was told that the program was written in dotNet 4.0. I'll get the error message and application event logs tomorrow when I go back into the office.
This is from the detail error message when the application is opened:
Problem Event Name: CLR20r3
Problem Signature 01: SPAAR.exe
Problem Signature 02: 22.214.171.124
Problem Signature 03: 54216f68
Problem Signature 04: SPAAR
Problem Signature 05: 126.96.36.199
Problem Signature 06: 54216f68
Problem Signature 07: df
Problem Signature 08: 71
Problem Signature 09: System.NullReferenceException
OS Version: 6.1.7601.2.1.0.256.4
Locale ID: 1033
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
at SPAAR.Form1.Form1_SizeChanged(System.Object, System.EventArgs)
at System.Windows.Forms.Control.UpdateBounds(Int32, Int32, Int32, Int32, Int32, Int32)
at System.Windows.Forms.Control.UpdateBounds(Int32, Int32, Int32, Int32)
at System.Windows.Forms.Control.SetBoundsCore(Int32, Int32, Int32, Int32, System.Windows.Forms.BoundsSpecified)
at System.Windows.Forms.Form.SetBoundsCore(Int32, Int32, Int32, Int32, System.Windows.Forms.BoundsSpecified)
at System.Windows.Forms.Control.ScaleControl(System.Drawing.SizeF, System.Windows.Forms.BoundsSpecified)
at System.Windows.Forms.ScrollableControl.ScaleControl(System.Drawing.SizeF, System.Windows.Forms.BoundsSpecified)
at System.Windows.Forms.Form.ScaleControl(System.Drawing.SizeF, System.Windows.Forms.BoundsSpecified)
at System.Windows.Forms.Control.ScaleControl(System.Drawing.SizeF, System.Drawing.SizeF, System.Windows.Forms.Control)
at System.Windows.Forms.ContainerControl.Scale(System.Drawing.SizeF, System.Drawing.SizeF, System.Windows.Forms.Control)
at System.Windows.Forms.ContainerControl.PerformAutoScale(Boolean, Boolean)
The exception, "System.NullReferenceException", says that you're trying to get/set a property of call a method on an object that your code is ASSUMING exists, but doesn't. You're not checking for the existence of the object you're trying to do something with before you try and use it.
Somewhere in the method "Form1_SizeChanged", you goofed.
Thank you. The client in question has 4.5 installed. Would it fix the issue if I uninstall 4.5.2 and installed 4.0? I tried that and it didn't work so don't know if I correctly uninstall 4.5.2 completely.
It should never be necessary to "uninstall" a particular version because they can all co-exist.
You just need to insure that the app you are trying to run has a compatible framework installed.
Leave 4.5 alone and install the 4.0 frameworks from the Microsoft sites. Try the "full" 4.0 framework; if that doesn't work, try the "client profile" (though that probably won't make a difference if the "full" 4.0 doesn't work).
Though the log doesn't seem to reflect it, the app could be trying to use something else that is missing if the app install you were given was incomplete; e.g. SQL Server CE dll's; 3rd party libraries).
The person who created the app should really be involved.
Last Visit: 31-Dec-99 19:00 Last Update: 23-Nov-14 17:32