Wrox Programmer Forums
|
VB Databases Basics Beginning-level VB coding questions specific to using VB with databases. Issues not specific to database use will be redirected to other forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB Databases Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 8th, 2005, 10:00 AM
Registered User
 
Join Date: Apr 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to jPaulB
Default What could be wrong???

Hi Folks,
I've just used the "Data Form Wizard" in VB6. This is a starting
point for me to learn something about data management in VB6

So that's all I did... used the wizard. Didn't do anything else,
I swear. ( It's all the Wizards' fault! )

Anyway, the wizard obviously wrote some code for me... but
when I attempt to run the debug and "see" all I've accomplished...
I get the following error:

************************************************** **
* Compile error
*
* Procedure declaration does not match description of event or
* procedure having the same name.
************************************************** **
I understand the nature of this kind of "error", but
the interesting thing is.... and <b>this is my question</b>:

If I delete ALL of the "Private Sub"s written by the Wizard, the test
will work. It seems that the Data Form Wizard wrote a bunch of code
that has little to do with the test.

I don't think the Wizard made mistakes, otherwise there would be a
huge "<i>Microsoft.public.vb.HATE.wizards</i>" forum going on.
It must be a choice I made in the properties.... somewhere... but I am so new that this IS a show-stopper.

Can anyone help me with this. I'm not even competent to "read" my own
code yet much less second-guessing a Wizard.

Regards,

Paul
 
Old April 8th, 2005, 11:45 AM
Friend of Wrox
 
Join Date: Nov 2004
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

You could try a couple of approaches.

1. Delete 1 sub at a time that the wizard's ignorant apprentice wrote for you, till the code will start.
   The last one you deleted to make it start is the problem.

2. Perhaps that step isn't necessary... one at a time, within the module that the private routines are in, add a call to the private routine. As you are entering the characters for the call, intellisense should show you an argument list. Once you have that, see if it matches the other uses of the routine.

(You should have a look at the Forum Code link for how to make bold, italic, colored text, [u]underlined</u>, etc. HTML doesn't work.)
 
Old April 10th, 2005, 01:16 PM
Authorized User
 
Join Date: Apr 2005
Posts: 16
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi JPaul

This is a property set/get/let error.

The property let was, lets say, a string whilst the property get is a , lets say, boolean. VB will not compile.

Go through all the properties. Welcome to the world of debugging. It's like the earth 90% water = 90% debugging, 10% land = 10% coding.

Regards

Helga Anagnostopoulos
 
Old April 11th, 2005, 10:14 AM
Friend of Wrox
 
Join Date: Nov 2004
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

90 : 10 ?? Wow!

But also, does the data form wizard create classes?
Or does it add properties to forms?
(I’d be surprized if it does either of those, though of course it is possible.)
 
Old October 20th, 2005, 09:12 PM
Registered User
 
Join Date: Oct 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have a the same problem with the code that the add-in wizard created for me as well. When I compare the project to the sample code downloaded from the website (which I can get to run without a problem) the only difference is in the lines:

<My code from the wizard in frmFirst>
Connect = "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source=C:\BegDB\BIBLIO.MDB;"
OLEDBString = "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source=C:\BegDB\BIBLIO.MDB;"

<Sample Code from internet in frmFirst>
Connect = "PROVIDER=Microsoft.Jet.OLEDB.3.51;Data Source=C:\BegDB\Biblio.mdb;"
OLEDBString = "PROVIDER=Microsoft.Jet.OLEDB.3.51;Data Source=C:\BegDB\Biblio.mdb;"

Thats it, so it looks like the Jet.OLEDB.4.0 vs. 3.51 is causing some problems, is the a quick way to fix this (cause im gonna get the same error in all the examples) or do i have to manually go out and change from 4.0 to 3.51 in every DB form i create.

Thanks for any advise you can give.






Similar Threads
Thread Thread Starter Forum Replies Last Post
What's wrong ??? FT BOOK: ASP.NET Website Programming Problem-Design-Solution 2 November 3rd, 2005 09:18 AM
Help..What am I doing wrong... Brettvan1 VB.NET 2002/2003 Basics 2 October 18th, 2004 02:36 AM
Where did I go wrong??? ahc2inc VB.NET 2002/2003 Basics 3 September 28th, 2004 08:19 PM
What's wrong?Help! amu BOOK: Beginning ASP.NET 1.0 1 October 28th, 2003 08:21 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.