471,120 Members | 1,454 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,120 software developers and data experts.

problem in running the exe on any location other than debug folder

198 100+
Hi
i am getting probleum in running the exe on any other location on my computer except bin\debug when i execute the exe file which is in bin\debug folder it works fine and when i copy this exe and save on any location like desktop ,D:,C: it shows a dialog box which contains the follwoing errors
************************************************** ***********************************
System.IO.FileNotFoundException: Could not load file or assembly 'Interop.DAO, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
File name: 'Interop.DAO, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null'
at Create_FinTiff.frmMain.frmMain_Load(Object sender, EventArgs e)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Mes sage& m)
at System.Windows.Forms.ContainerControl.WndProc(Mess age& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.O nMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.W ndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
************************************************** ****************************************
please tell me what is going to be wrong with my code or how i can make my exe so that it could not display this error

with best regards
varinder
Jun 7 '08 #1
5 2385
CyberSoftHari
487 Expert 256MB
You should do proper installation, there may some dll, Ocx or any third party tool may missing which is having reference to your project.
Jun 7 '08 #2
Plater
7,872 Expert 4TB
What other files are in that directory?
There is probably the interop dll you use sitting there with it.
Jun 9 '08 #3
veer
198 100+
Hi
yes there is interop.dll file in the debug directory and many other files like interop.dao.dll,interop.excel.dll,interop.adodb.dl l ,office.dll and if i copy all the files in the other directory with exe then it works fine .Is there any thing wrong in my project so that with out these dll files how can i run my exe
i also want to know
------ every time when i execute my programe the follwoing lines are displayed in immediate window

A first chance exception of type 'System.IO.IOException' occurred in Microsoft.VisualBasic.dll

what does this mean








What other files are in that directory?
There is probably the interop dll you use sitting there with it.
Jun 10 '08 #4
vijayB
40
Hi
yes there is interop.dll file in the debug directory and many other files like interop.dao.dll,interop.excel.dll,interop.adodb.dl l ,office.dll and if i copy all the files in the other directory with exe then it works fine .Is there any thing wrong in my project so that with out these dll files how can i run my exe
i also want to know
------ every time when i execute my programe the follwoing lines are displayed in immediate window

A first chance exception of type 'System.IO.IOException' occurred in Microsoft.VisualBasic.dll

what does this mean
Hmmm,
The exe which is getting created in bin\debug folder is not the actual one.
Build your project in release mode, you will get same exe at bin\release.
Then either use installshield or you can use setup wizard provided by VS 2k5 IDE. Through any of the above create setup, properly install it like any other software.
It should work..
Jun 10 '08 #5
veer
198 100+
thanks for reply
it is working

i asked you antoher question in my previous post
how i disable exception like "A FIRST CHANCE EXCEPTION OCCURS OF TYPE " in vs2008

i got the idea by browsing on net and find
tools\options\debuging
but im not getting the debugging tab

is it right method if not then please how to do it


varinder



Hmmm,
The exe which is getting created in bin\debug folder is not the actual one.
Build your project in release mode, you will get same exe at bin\release.
Then either use installshield or you can use setup wizard provided by VS 2k5 IDE. Through any of the above create setup, properly install it like any other software.
It should work..
Jun 11 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

2 posts views Thread by Visually Seen # | last post: by
1 post views Thread by Peter | last post: by
2 posts views Thread by Richard Lionheart | last post: by
13 posts views Thread by Lee Newson | last post: by
5 posts views Thread by Segfahlt | last post: by
8 posts views Thread by =?Utf-8?B?TWlrZSBSYW5k?= | last post: by
reply views Thread by james.mcdonagh | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.