Link to home
Start Free TrialLog in
Avatar of Timelib
Timelib

asked on

FileSystemObject, with VB 6 and Windows XP

I've been trying to use the Scripting.FileSystemObject in VB 6 on my Windows XP Pro machine.

The object doesn't seem to exists, from what the error messages are returning:

"User-defined type not defined"

Has the scripting code changed between win2000 and XP?

Has anyone been able access folders and file information with VB 6 on XP?

Note: Unsure, but, do I have to install windows scripting on XP?
ASKER CERTIFIED SOLUTION
Avatar of Brian Mulder
Brian Mulder
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
You're right that Windows Scripting is needed to run FSO. Not sure though w.r.t. XP. Otherwise, as suggested already by bruintje, you can use other methods, so that you dont need to reference to one more DLL in your project.

Still if you wish to use FSO, just check scrrun.dll is there in your system and also registered: i.e.
Start/Run - RegSvr32.exe scrrun.dll

Hope it helps.
Avatar of Timelib
Timelib

ASKER

scrrun.dll is in XP Pro, and registered but its not except it as defined.

What API functions can be called, and were can I get examples or more information on them?
Avatar of Timelib

ASKER

I've wrote with the FSO before, I just forgot one minor step......binding (referencing) the scrrun.dll first.....

And I call my self a programmer....

Thanks for the help.
We had faced problems with FSO, say, if a system does not have Windows Scripting Host(hope, this could happen, if Internet Explorer installed in Win95 is default one, and not like IE4 or IE5). Then your program wont run, causing error.

So, recommend not using FSO, otherwise include it(scrrun.dll) in your project installation and register in installation PC.

Hope it helps.