Help: Why does updating occur in the form created by the VB Data Forms Wizard even when I don't want it to?

Help: Why does updating occur in the form created by the VB Data Forms Wizard even when I don't want it to?

Post by Dean Malandr » Tue, 30 Jun 1998 04:00:00



Using the VB Data Forms Wizard in VB5, I've created a form with a dozen
fields in it; 6 from Table A and 6 from Table B. The code just places a data
control on the form, points all the text boxes towards this control as their
data source, and throws add, delete, refresh, update, and close buttons on.
I'm sure everyone has played with this feature when doing their first
database application.

Standard fare, but I have a problem with this, for if I type anything into a
text box or modify the contents of a text box, the field in the underlying
table gets updated automatically, without needing to press the update
button. Closing the form and re-opening it, or exiting the application and
looking at the database with some other method, and there is the new data.
This is not good, as I want to have to press the update button to update,
not just have it siphon in as soon as I type.

Is there a fix for this? I've looked at some sample applications done the
same way, and they all suffer the same problem: the update button is
redundant and the data in the underlying tables is modified live.
--
Win95 Error: 079 Mouse not found - A mouse driver has not been installed. Please click the left mouse button to continue.  
----------------------------------------------------------------------------
Plexus Technologies Pty. Limited. Electronics Consulting, Research & Development.
http://www.plexus-technologies.com
Mobile: +61 (0)411 470 880
ICQ: 719010

 
 
 

Help: Why does updating occur in the form created by the VB Data Forms Wizard even when I don't want it to?

Post by Eric Dimayug » Tue, 30 Jun 1998 04:00:00


That's what it means when it says the text boxes are bound to the data, it
goes both ways. You could have them not bound, then cycle through each text
box and put their values into the database when the user clicks on the
update button. The update button is normally for multi-user apps to see any
changes another user has made.


>Using the VB Data Forms Wizard in VB5, I've created a form with a dozen
>fields in it; 6 from Table A and 6 from Table B. The code just places a
data
>control on the form, points all the text boxes towards this control as
their
>data source, and throws add, delete, refresh, update, and close buttons on.
>I'm sure everyone has played with this feature when doing their first
>database application.

>Standard fare, but I have a problem with this, for if I type anything into
a
>text box or modify the contents of a text box, the field in the underlying
>table gets updated automatically, without needing to press the update
>button. Closing the form and re-opening it, or exiting the application and
>looking at the database with some other method, and there is the new data.
>This is not good, as I want to have to press the update button to update,
>not just have it siphon in as soon as I type.

>Is there a fix for this? I've looked at some sample applications done the
>same way, and they all suffer the same problem: the update button is
>redundant and the data in the underlying tables is modified live.
>--
>Win95 Error: 079 Mouse not found - A mouse driver has not been installed.

Please click the left mouse button to continue.

- Show quoted text -

Quote:>---------------------------------------------------------------------------
-
>Plexus Technologies Pty. Limited. Electronics Consulting, Research &
Development.
>http://www.plexus-technologies.com
>Mobile: +61 (0)411 470 880
>ICQ: 719010


 
 
 

Help: Why does updating occur in the form created by the VB Data Forms Wizard even when I don't want it to?

Post by N » Wed, 01 Jul 1998 04:00:00


Buy a book before starting in this manner!

These datacontrols behave this way because you haven't learned to suppress
this behaviour yet!

(Validate event, UpdateControls)

Dean Malandris heeft geschreven in bericht

Quote:>Using the VB Data Forms Wizard in VB5, I've created a form with a dozen
>fields in it; 6 from Table A and 6 from Table B. The code just places a
data
>control on the form, points all the text boxes towards this control as
their
>data source, and throws add, delete, refresh, update, and close buttons on.
>I'm sure everyone has played with this feature when doing their first
>database application.

>Standard fare, but I have a problem with this, for if I type anything into
a
>text box or modify the contents of a text box, the field in the underlying
>table gets updated automatically, without needing to press the update
>button. Closing the form and re-opening it, or exiting the application and
>looking at the database with some other method, and there is the new data.
>This is not good, as I want to have to press the update button to update,
>not just have it siphon in as soon as I type.

>Is there a fix for this? I've looked at some sample applications done the
>same way, and they all suffer the same problem: the update button is
>redundant and the data in the underlying tables is modified live.
>--
>Win95 Error: 079 Mouse not found - A mouse driver has not been installed.

Please click the left mouse button to continue.

- Show quoted text -

Quote:>---------------------------------------------------------------------------
-
>Plexus Technologies Pty. Limited. Electronics Consulting, Research &
Development.
>http://www.plexus-technologies.com
>Mobile: +61 (0)411 470 880
>ICQ: 719010

 
 
 

1. Strange Behavior in Data Form Wizard created Form

I'm creating a simple data access/update app in VB6 and have run into
something strange when using the "Data Form Wizard" to create a new data
form.

After following the wizard through its steps, (connecting to my SQL Server
database, choosing the table, choosing the fields, etc.) I end up with a
data form that seems to run fine at first. The fields populate correctly and
I can add and delete records without a problem. However, when I try to
update a field I get an E_FAIL error. The problem seems to be that the data
fields are populated with the data and trailing spaces. So if I update a
field, say "FirstName" from "Ken" to "Kenneth", I get the E_FAIL error.
However, if I make the update and delete the trailing spaces, the update
works.

Have you ever seen this? What can I do to fix this? I want to use the
wizards to speed up application development but not if updating fields won't
work properly.

Thank you for any help!
Ken

2. Question re. Sybase, NT and backup procedures

3. VB Data form wizard

4. pg_log ??

5. VB Data Form Wizard error

6. DTS programming in VB

7. Question about Data Form Wizard in VB

8. Function to return a table with variable number of NULL columns

9. Source code for VB's Data Form Wizard

10. VB Data Form Wizard

11. vb DATA form wizard

12. VB Data Form Wizard

13. VB data form wizard and access 2000