I did some VB code at home (with a Windows XP machine, running Visual Studio 6), compiled an exe file, everything worked fine. Tried the exe file on another Windows2000 machine (with VS6 installed), worked fine. (My user has a Windows 2000 machine.)
Sent the exe file to the user, it didn't work, poping up an error message saying stuff like "ActiveX can't create object". I figured he's missing some components that probably comes with VS6 installation? So I packaged my project with PDW, ended up with a 27M package. Post it online, get my user to download it, unzip and run setup, restart, still not working.
Then I sent all project files to my Windows2000 machine, hoping to package it there to make sure it's not operating system issue. Meanwhile I changed a little bit in the code, so I want to recompile first. But this machine gives me a compile error saying "cannot find library"! with the cursor pointing at a "Trim" function in my code. So maybe there's some reference I need to include in VB at this machine, but which one is for "trim" function? Please help! I pasted some of my code here, just in case anybody wants to see it. Also, if you have any idea on how to make it work on any other machine, please point out. Thanks a lot.
Private Sub menuOpen_Click()
Dim strOpenFile As String, fileExist As Boolean, i As Integer, openOk As Boolean
Dim fsoFile, mySplit, mySplitStr
fileExist = False
Set fsoFile = CreateObject("Scripting.FileSystemObject")
CommonDialog2.Filter = "All Files (*.*)|*.*"
strOpenFile = CommonDialog2.FileName
If (Trim(strOpenFile) = "") Then Exit Sub
If (fsoFile.fileExists(strOpenFile) = False) Then
MsgBox ("File does not exist. Please select an existing file.")
fileExist = True
Loop While fileExist = False