-
Hi Everyone,
I must be about the dumbest programmer out there, with all the question that I put up here.
In the program that I'm working on I have a drive box(drive1)and a direcotry box (dir1). When the program is compiled and installed on a Windows 95 or 98 box, if the user clicks on either drive1 or dir1 the program crashes. I have a Windows NT machine and the program works fine on it, it was also tested on another NT box and works fine on it. Any suggestions as to why it is crashing until 95 or 98?? The error number is either 52 or 32 sorry I can not remember for sure which one.
-
Are you compiling on a W9x or Win NT? If on NT then try to compile it on a W9x box.
-
I'm compiling under NT, I do not have access to a 95 or 98 box to compile on.
Could this be the problem??
-
I have seen it before.
Created a new EXE project and include:
Form - Form1
Textbox - Text1
DriveListBox - Drive1
DirListBox - Dir1
FileListBox - File1
Add the following code and compile. Now try it on both machines. If it still locks up then post your email address and I will send you my compiled version.
Option Explicit
Private Sub Form_Initialize()
Text1.Text = Drive1.Drive
Me.Refresh
End Sub
Private Sub Drive1_Change()
Dir1.Path = Drive1.Drive
Text1.Text = Drive1.Drive
Me.Refresh
End Sub
Private Sub Dir1_Change()
File1.Path = Dir1.Path
Text1.Text = Dir1.Path
Me.Refresh
End Sub
Private Sub File1_Click()
Text1.Text = File1.Path & "\" & File1.FileName
Me.Refresh
End Sub
-
A little error handling would help you in 2 ways:
1. Your program wouldn't crash.
2. You might find out a better description of what's going on.
On Error Goto ErrHandler:
ErrHandler:
Msgbox "An error has occurred! Error number: " & Err.Number & vbcrlf & Err.Description
Resume Next
:D
-
Thanks. I now have 2 machines so I'm working on both of them, one is 98 and the other is NT. I have found the problem. I do have error checking, but for some reason one or two modules got missed.
Thanks for all the help though.