Where to put the code? 
Author Message
 Where to put the code?

Where to put the code?

I'm playing around with VC++ 6.0 and its database access.  I created a
simple database app using ODBC and the default MFC template.

First I created a System DSN entry to the database I wanted (MS Access).  I
then used MFC AppWizard (exe) to create my frame work.  SDI for the document
support.  Database view without file support. I didn't need the
serialization..  Data Source ODBC and selected my DSN entry..Snapshot was
also selected. Then the defaults the rest of the way.

I have succesfully been able to Display the data on the dialog and mapped
the Edit Boxes with the required fields and the previous/next arrow icons
work just fine.   I have even added a combo box for "sort" options and an
edit box for additional SQL query statments to scan the database.

Now my question/problem:  I would like to add some static displays such as:
Rec [ 1 ] of [150].  I am able to figure out what record I currently have
and the total number in the list.  I even know how to update the static
objects.  My problem is I have no clue where to put this code.  Every place
I put it doesn't update the dialog.  I have made sure to use the
UpdateData(FALSE)  to make sure everything has been written to the dialog.
When the prev/next icons are used and right before the dialog is update I
would like to adjust these static objects.

Any and all help would be greatly appricated.


David D. Cruger

Fri, 26 Jul 2002 03:00:00 GMT  
 [ 1 post ] 

 Relevant Pages 

1. Question about ATL services, where to put user code

2. where should I put this code?

3. where's a good place to put this code

4. why can't we put serverside code in page class-declaration?

5. how to put SQL code in a C program?

6. Is it possible to put finalize code for "Stop Debugging"?

7. putting executable code into an external file

8. Need utility to put code at beginning and end of functions

9. Repeated code -> put it in a function

10. Where do I put long dialog startup code?

11. beginner graphics woe: code to put dot on screen works only w/ breakpoints

12. Where to put code in MDI database app?


Powered by phpBB® Forum Software