Groups | Blog | Home
all groups > vb.net > january 2006 >

vb.net : Error Trapping for trying to run an exe file without supporting files


PJ on Development
1/11/2006 4:01:31 PM
Hi Paul,

Well, the easiest way to do this is to check for the file presense
before running any real code.

I use to check for the files I need first, and when I don't find them I
ask the user where they are and store it on my application settings
(INI File, Registry, whatever) so the next time I know where to look
when I need them.

But if the files you need are somewhat a must have (such as Assemblies,
and other supporting file) then instead of asking the user where the
files are you just show the user an error message and exit the
application gracefully.

I hope it helps,

PJ
http://pjondevelopment.50webs.com
Paul Bromley
1/11/2006 7:54:39 PM
I have distributed an exe file that depends on a number of other files and
directories within the application directory. Do not ask me why some peopel
should choose to do this, but for some strange reason a number of people are
trying to run the exe file from the desktop or elswhere outside the file
structure that is required. Is there any easy way of error checking this,
and informing the user??

Best wishes

Paul Bromley

Paul Bromley
1/14/2006 8:27:06 PM
Thanks PJ,

I thought that there may be an easier way rather than checking all my
required files, but I will do this.


Thanks

Paul

[quoted text, click to view]

AddThis Social Bookmark Button