JIT Debugger Error message caused by filelistbox

I have been working on a program and testing it on another computer that has the .Net framework installed. My program works fine on my computer with .Net installed. However, when I run it on the other computer (with only the framework installed) I get a random error:

MyApp.exe - Common Language Runtime Debugging Services

Application has generated an exception that could not be handled.

Process id=0xf3c (3900), Thread id=0xf64 (3940).[The numbers in this error line are different everytime]

When I hit cancel to debug it displays

MyApp.exe - No debugger found.

Registered HIT debugger is not available. An attempt to launch a JIT debugger with the following command resuled in an error code of 0x2 (2). Please check computer settings.

cordbg.exe !a 0xf3c[The numbers in this error line are different everytime]

My program worked fine until I added a filelistbox. Both computers meet the requirements for the .Net. When I build my program it is set to release.

Thankyou

White Hawk

[1325 byte] By [WhiteHawk] at [2007-12-24]
# 1

It might be useful to see some code. It sounds like whatever you're doing with the filelistbox is not thread safe. Due to the very nature of threading, these problems can appear on one computer and not at all on another. It's like memory management in C etc...

The warnings about debuggers not being available you can ignore, that's just saying it couldn't find anything to debug the exception.

Does this happen every time you perform a specific action? Or whenever you try and launch it on the other comp?

weirdbeardmt at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 2

If that is the case then I am even more perplexed. Here is the reason. I know it has nothing to do with the code. However, to make sure I created a blank program with no code and build it. I then added a filelistbox (not writing any code) and built it in another location.

When I ran the blank app on the troublesome computer it worked. Yet, when I ran the blank app w/ filelistbox it gave me the same errors. (I get these errors as soon as I try to open the .exe file).

What am I doing wrong? My other program (doesn't have a filelistbox) works fine on the troublesome computer.

Thankyou for the help

-White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 3
Is this a VB6 app? If you're developing under the .NET framework, you should really be using the openfiledialog instead.
weirdbeardmt at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 4

This is under .net framework. I need to use the filelistbox because I can load all the files from a directory into the filelistbox. I can use a normal listbox but it is a lot slower. I need to load a lot of files that is why I used a filelistbox.

-White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 5

Is there some reason a filelistbox will not work on a computer that only has the framework on it, or am I doing something wrong?

If anyone could help I would greatly appreciate it.

-White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 6

Assuming that you have the correct version of the .NET framework installed on the machine, the application should work.

If I had this problem, I would assume that there was a problem with my application. Maybe you can set up a remote debugging session to get some more information as to exactly what it is that is blowing up.

Best regards,
Johan Stenberg

MSJohanStenberg at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 7

I must be doing something wrong, because for some reason a new blank program fails only when I add a filelistbox. Both work fine on my computer with VB.NET, however I get the random errors as described above with the new blank program w/ filelistbox on the other computer.

I am sorry for the trouble.

I will try remote debugging. Although it can't be code if I didn't enter any to begin with.

<EDIT> I just tried using a Drivelistbox and a Dirlistbox (Tried each individually) and got the same errors on the other computer? When I added a regular listbox it worked on the other computer. This is weird.</EDIT>

-White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 8

How are you deploying your application to the other computer? And are you sure that the app is allowed to read from the file system on that machine?

Best regards,
Johan Stenberg

MSJohanStenberg at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 9

I am sorry but I am new to the .Net arena. How do I know if the app is allowed to read from the file system on the desktop (the desktop computer is having the problems).

As far as deploying my app. I build it in release form and copy the .exe file onto the desktop computer.

Thanks,

White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 10

Does anyone know how to fix this file system reading? How can I tell if the application is allowed to read the file system on the computer? If it can't how do I fix it?

Thanks,

White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 11
Which directory are you trying to read the files from? Does the directory exist on the target computer? Are you logged in as an Admin or a different user level?
weirdbeardmt at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 12
Also, have you signed the assembly using a strong name? Do you have option strict turned on?
weirdbeardmt at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 13

-I haven't written any code in the sample program I made to test this problem, so it reads from the default directory.

-I am testing it on my home desktop so administrative privileges shouldn't be a problem.

-Have I signed the assembly using a strong name? I am sorry but I am still new to this. What do you mean?

-I don't think I have option strict turned on. Would that make a difference as far as this problem goes?

Thankyou for the help,

White Hawk

WhiteHawk at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...
# 14

OK, I think I've sorted this. I'm 99% confident it's because you haven't signed the the assembly. I suspect the error you'd see if you had a debugger installed on the other machine is that your app is not trusted. It's a security thing.

Right click the project and choose signing, then in the menu choose "New". I think it guides you through the process (it's quite simple).

weirdbeardmt at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic General...