NateDizzle
asked on
Deployment: System.IO.FileNotFoundException:
I am deploying a small database program onto an office computer. The program runs seemlessly on the computer it has been developed on. I created an msi project to install the program.
When I run the program all is fine except for when I click on one button on a second dialog form.
The appropiate .Net Framework has been installed on the computer where I am having trouble.
************** Exception Text **************
System.IO.FileNotFoundExce ption: The specified module could not be found.
at E_Tracker.AddRecord.Button 3_Click(Ob ject sender, EventArgs e)
at System.Windows.Forms.Contr ol.OnClick (EventArgs e)
at System.Windows.Forms.Butto n.OnClick( EventArgs e)
at System.Windows.Forms.Butto n.OnMouseU p(MouseEve ntArgs mevent)
at System.Windows.Forms.Contr ol.WmMouse Up(Message & m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Contr ol.WndProc (Message& m)
at System.Windows.Forms.Butto nBase.WndP roc(Messag e& m)
at System.Windows.Forms.Butto n.WndProc( Message& m)
at System.Windows.Forms.Contr olNativeWi ndow.OnMes sage(Messa ge& m)
at System.Windows.Forms.Contr olNativeWi ndow.WndPr oc(Message & m)
at System.Windows.Forms.Nativ eWindow.Ca llback(Int Ptr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
************** Loaded Assemblies **************
mscorlib
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/microso ft.net/fra mework/v1. 1.4322/msc orlib.dll
-------------------------- ---------- ----
E-Tracker
Assembly Version: 1.0.1579.14858
Win32 Version: 1.0.1579.14858
CodeBase: file:///C:/Program%20Files /E-Tracker /E-Tracker _inst/E-Tr acker.exe
-------------------------- ---------- ----
System.Windows.Forms
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl y/gac/syst em.windows .forms/1.0 .5000.0__b 77a5c56193 4e089/syst em.windows .forms.dll
-------------------------- ---------- ----
System
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl y/gac/syst em/1.0.500 0.0__b77a5 c561934e08 9/system.d ll
-------------------------- ---------- ----
Microsoft.VisualBasic
Assembly Version: 7.0.5000.0
Win32 Version: 7.10.3052.4
CodeBase: file:///c:/windows/assembl y/gac/micr osoft.visu albasic/7. 0.5000.0__ b03f5f7f11 d50a3a/mic rosoft.vis ualbasic.d ll
-------------------------- ---------- ----
System.Drawing
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl y/gac/syst em.drawing /1.0.5000. 0__b03f5f7 f11d50a3a/ system.dra wing.dll
-------------------------- ---------- ----
System.Data
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl y/gac/syst em.data/1. 0.5000.0__ b77a5c5619 34e089/sys tem.data.d ll
-------------------------- ---------- ----
System.Xml
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl y/gac/syst em.xml/1.0 .5000.0__b 77a5c56193 4e089/syst em.xml.dll
-------------------------- ---------- ----
Interop.DSOleFile
Assembly Version: 1.4.0.0
Win32 Version: 1.4.0.0
CodeBase: file:///C:/Program%20Files /E-Tracker /E-Tracker _inst/Inte rop.DSOleF ile.DLL
-------------------------- ---------- ----
When I run the program all is fine except for when I click on one button on a second dialog form.
The appropiate .Net Framework has been installed on the computer where I am having trouble.
************** Exception Text **************
System.IO.FileNotFoundExce
at E_Tracker.AddRecord.Button
at System.Windows.Forms.Contr
at System.Windows.Forms.Butto
at System.Windows.Forms.Butto
at System.Windows.Forms.Contr
at System.Windows.Forms.Contr
at System.Windows.Forms.Butto
at System.Windows.Forms.Butto
at System.Windows.Forms.Contr
at System.Windows.Forms.Contr
at System.Windows.Forms.Nativ
************** Loaded Assemblies **************
mscorlib
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/microso
--------------------------
E-Tracker
Assembly Version: 1.0.1579.14858
Win32 Version: 1.0.1579.14858
CodeBase: file:///C:/Program%20Files
--------------------------
System.Windows.Forms
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl
--------------------------
System
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl
--------------------------
Microsoft.VisualBasic
Assembly Version: 7.0.5000.0
Win32 Version: 7.10.3052.4
CodeBase: file:///c:/windows/assembl
--------------------------
System.Drawing
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl
--------------------------
System.Data
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl
--------------------------
System.Xml
Assembly Version: 1.0.5000.0
Win32 Version: 1.1.4322.573
CodeBase: file:///c:/windows/assembl
--------------------------
Interop.DSOleFile
Assembly Version: 1.4.0.0
Win32 Version: 1.4.0.0
CodeBase: file:///C:/Program%20Files
--------------------------
ASKER
it displays a file dialog / folder dialog dependent on a variable. Then it uses the dsolefile.dll to get the document properties (title) from a file if a file was chosen.
I originally assumed that the dsolefile was the problem, but it indicates that it has been loaded and the dll file and interop file have been transferred to the other computer.
I originally assumed that the dsolefile was the problem, but it indicates that it has been loaded and the dll file and interop file have been transferred to the other computer.
My first thought was that it was probably the application unable to locate the Interop.DSOleFile.DLL. Is this definitely located in the application folder on the machine it is not working properly on?
If it is, then could you add the code that you are using for the button click.
Tom
If it is, then could you add the code that you are using for the button click.
Tom
ASKER
As I debug this myself I have discovered that the dsolefile is the problem specifically these two lines:
Dim PropReader As New DSOleFile.PropertyReader
Dim Props As DSOleFile.DocumentProperti es
Dim PropReader As New DSOleFile.PropertyReader
Dim Props As DSOleFile.DocumentProperti
ASKER
OKAY!
So I solved it, vb was referring to the file path of the Dsole.dll on my computer. So i pointed it to the c:\ drive and placed the dll in that folder in the other computer.
WHY doesn't vb redirect this reference when it moves the dll with the distribution package???? This is beyond me, it installed the dll onto the other computer but doesn't change the path of the reference. There must be something I overlooked to get VB to do this, right?
So I solved it, vb was referring to the file path of the Dsole.dll on my computer. So i pointed it to the c:\ drive and placed the dll in that folder in the other computer.
WHY doesn't vb redirect this reference when it moves the dll with the distribution package???? This is beyond me, it installed the dll onto the other computer but doesn't change the path of the reference. There must be something I overlooked to get VB to do this, right?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Tom