|
-
Sep 21st, 2000, 05:33 PM
#1
Thread Starter
PowerPoster
I have to create a program which will read and write to a dbase 4 database. I have no idea how to accomplish this...
Can anyone please help.
I have used the data control in the past to just view the data, but never add or update. Any experts in this area?
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Sep 21st, 2000, 06:34 PM
#2
Thread Starter
PowerPoster
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Sep 21st, 2000, 06:53 PM
#3
Hyperactive Member
I am pretty new at this, however I have some experience in DB programming. The only information that I can give you is to walk through the Database tutorial in this site. Karl Moore wrote it and it is excellent!
I read through it, and it was pretty easy to pick up on.
You will need to use and understand the ADO control, for adding records.
I hope this helps!
Lee
 Mahalo 
VB6(SP5), VC++, COBOL, Basic, JAVA
MBA, MCSD, MCSE, A+
Computer Forensics
-
Sep 21st, 2000, 09:06 PM
#4
Thread Starter
PowerPoster
Thanks Lee M
Can it be done without the ADO control?
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Sep 21st, 2000, 09:18 PM
#5
_______
<?>
I have never used dbase only access mdb with dao. Does dbase use the same source information. Do you know how to start..ie open the database and read the information or set your datasource or anything?
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Sep 21st, 2000, 09:23 PM
#6
Thread Starter
PowerPoster
Not a damn clue...
Just trying to learn... Really need to figure out.
Like I said before, I have used the data control to view the data, but now I must be able to read and write the data. The ONLY reason I am using dbase4 for this application is that it must be compatible with an old Lotus 5.0 spreadsheet based applications which uses dbase4 exclusively. (I won't bore you with all the details).
Please anyone help... ? ? ? !!!
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Sep 21st, 2000, 10:30 PM
#7
Fanatic Member
Dear James...
I don't know whether this will help u or not. Currently, I'm using three databases. My primary database is SQL Server ver 7.0, my secondary database is Ms-Access 2000, and my last database is dBase III.
In Order to connect to those three databases, I'm using full hard-coding of database connection and recordset. I never use data control.
You can connect using ODBC DSN or DSN-less connection. But, for the easiest connection, I suggest u use ODBC DSN.
First of all, you should create a DSN name at your ODBC Data Administrator at your control panel system.
Let say your DSN Name is dBaseConn
your code will be (in ADO Connection) :
Code:
Sub Open_Database()
Dim myDB as New ADODB.Connection
Dim myRS as New ADODB.Recordset
Dim mySQL as String
myDB.Open "DSN=dBaseConn"
mySQL = ... you SQL statement ...
myRS.Open mySQL, myConn, adOpenDynamics, adLockOptimistics, adCmdText
If (myRS.BOF <> True) and (myRS.EOF <> True) Then
'Record Found...
............
'you can add new record...
myRs.AddNew
myRs!yourfield = yourvalue
.....
myRs.Update
End If
myRS.Close
myDB.Close
End Sub
ok ???
hope will help
Cheers,
Wen Lie
-
Sep 22nd, 2000, 08:39 AM
#8
Thread Starter
PowerPoster
Thanks to all
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|