I did some searching and some digging.
Basically, i used the object browser to look up the exact syntax of the event. which you had correct except for a few poss errors (using the fuill name for objects can prevent some strange sounding errors). So that didn't work. Seacrhed some forums and found other people complaining about it. and some discussion about different version numbers of the ADO controls.
And eventually tracked down enough to work out which version(s) worked. Microsoft make no mention of this bug so we assume they have fixed it! I teach VB as part of my job - so I was interested enough to track this down for you.
I have emailed you the OCX file. Normally you have to regsiter ocx and dll files with windows. but as this is a new version I'm not sure. I would rename the old one (found in C:\windows\system32\MSADODC.OCX) to something else. then copy the new one in there.
you can manually register the file by opeining a command prompt and cd'ing to windows system32 then type:
that should register it. Now open your vb program and change the code as mentioned before. I have sent you two other files MSADODC.oca and MSADODC.DEP which might be needed by the ocx file. If all this fails, you'll need to download the service pack. Or if since you're in swansea I could post it to you on CD. You a student down there ICEMAN?
yeh i'm a college student, i made a website about vb actually for my college coursework: http://www.iceman-online.co.uk
p.s. Thx mate, works good and proper....... this was the only error left and i couldn't figure it out, thx
also you can download my phonebook at http://www.iceman-online.co.uk/phonebook.zip
Last question: Would it be a breach of copyright or any other similar law to include Microsoft Visual Basic Service Pack 4 with my program?
if you have a good enough version of vb6 - say enterprise edtion. then you will have the package and deployment wizard. It under add ins you might have to enable it - then look back again.
This will build full installers for your program inc all ocx files required.
Otherwise, providing you have a non-educational version of VB you can ship the executable along with the relevent files it requires to run. like all the ocx's. I don't think you can distibute MS service packs as they don't like it. Have you noticed that pc mags no longer come with these on?
If you haven't got the addin. finish your prog - send it to me and I'll build the installer for you. It will jump to about 10Mb. but it is worth it!
I used the Visual Studio Installer