|
-
how to update access database without sql
I have a courseework, that prohibits usage of sql within the code.
I have objects in array list. I have a connection to the Access table. How can i store the data from my arraylist into the table in Access.
I tried the following but it didn't work:
dataset.Tenant.Clear() ' tenant is the name of the table in access
For i = 0 To tenantList.Count - 1
dataset.Tenant.Item(i).tenantId = tenantList.Item(i).tenantno
dataset.Tenant.Item(i).firstName = tenantList.Item(i).tenantfname
dataset.Tenant.Item(i).lastName = tenantList.Item(i).tenantlname
dataset.Tenant.Item(i).tenantType = tenantList.Item(i).tenanttype
Next
adapterTen.Update(dataset.Tenant)
the following does not work either:
for i = 0 to tenantList.Count - 1
dataset.Tenant.AddTenantRow(tenantList.Item(i).tenantfname, tenantList.Item(i).tenantlname, tenantList.Item(i).tenantno, tenantList.Item(i).tenanttype)
next
can anybody help me?
Similar Threads
-
By rperez in forum Database
Replies: 5
Last Post: 01-02-2009, 04:14 PM
-
By ksuwanto8ksd in forum VB Classic
Replies: 1
Last Post: 06-14-2005, 02:42 PM
-
By Makl. Lemmertz in forum VB Classic
Replies: 2
Last Post: 10-29-2001, 11:12 AM
-
By Nate in forum Database
Replies: 29
Last Post: 05-09-2001, 10:04 AM
-
By deane in forum authorevents.mitchell
Replies: 0
Last Post: 10-16-2000, 10:41 PM
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
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks