Customer record IO -class, dll, or straight code?

Customer record IO -class, dll, or straight code?

Post by Todd Boy » Fri, 03 Oct 1997 04:00:00



Can anybody help with "strategic planning" on this?

I am working on a VB5 DAO accounting application which, like most
accounting systems, has a customer list.  I am noticing that there are
already four major places in the program where I need to go to the
disk to get a customer record, and go back and write it back again.

I don't want to maintain the same code in four places, every time the
Customer definition changes.  Furthermore, I want the code to be
upgradable from JET 3.5 to ODBC or ADO some day...

QUESTION 1- Does it make sense to have a class module (call it
clsCustomerIO) with methods ReadCust and WriteCust?

Q.2- My brain is telling me to define a "user defined type" which
would be returned by this ReadCust (or processed by WriteCust)
subroutine.  But I seem to recall I shuld be making an ActiveX or DLL
with publicly exposed property lets and property gets?  Is that
better?

Q.3-- Is this puppy going to run slower if I do this?  two of the four
places, I'm looping thru the customer list to perform tasks like
applying logic to synchronize the customer list with external
software.  Will the loop run significantly faster if I code it the
"old fashioned way" directly accessing the recordset in the loop?

Any help much appreciatd,
Thanks

 
 
 

1. Customer record IO -class, dll, or straight code?

Can anybody help with "strategic planning" on this?

I am working on a VB5 DAO accounting application which, like most
accounting systems, has a customer list.  I am noticing that there are
already four major places in the program where I need to go to the
disk to get a customer record, and go back and write it back again.

I don't want to maintain the same code in four places, every time the
Customer definition changes.  Furthermore, I want the code to be
upgradable from JET 3.5 to ODBC or ADO some day...

QUESTION 1- Does it make sense to have a class module (call it
clsCustomerIO) with methods ReadCust and WriteCust?

Q.2- My brain is telling me to define a "user defined type" which
would be returned by this ReadCust (or processed by WriteCust)
subroutine.  But I seem to recall I shuld be making an ActiveX or DLL
with publicly exposed property lets and property gets?  Is that
better?

Q.3-- Is this puppy going to run slower if I do this?  two of the four
places, I'm looping thru the customer list to perform tasks like
applying logic to synchronize the customer list with external
software.  Will the loop run significantly faster if I code it the
"old fashioned way" directly accessing the recordset in the loop?

Any help much appreciatd,
Thanks

2. VB5->VFP

3. A straight question, I need a straight Answer ?

4. psql scripts

5. DLL class - not working as a dll

6. APPLY CURSOR-UP TO BROWSER ==> malfunction

7. [Could not load class: sun.io.CharToByteISO8859_1]

8. How to break up a big transaction?

9. VFP5 adding code to the default code in a class

10. Customer Class examples

11. Unix filesystem: use buffered IO or direct IO?

12. NT Service with OCI Code cannot start with wsock32.dll code

13. Zip Code to long lat to help find customer