473,396 Members | 1,866 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Same problem of transfer of some access data to another access database

how can we transfer data from one access database to another databse . the table name is same for both the database . in one table some records are there (rs say e.g.) now another table has say rs+10 records . now i have to pass there 10 values to another table with same name . can anyone help me with this. i m usinf DAO
. i wrote some codes in dao. i created a function : AddTableField

i m writing it in module so that it can be access from anywhere in the program
this is the code

Sub AddTableField(ptdfTableDef As DAO.TableDef, pstrFieldName As String, pintDatatype As Integer, Optional pintSize As Integer, Optional pblnFixedLength As Boolean, Optional pblnAutoIncrement As Boolean, Optional pblnAllowZeroLength As Boolean, Optional pblnRequired As Boolean, Optional pstrValidationText As String, Optional pstrValidationRule As String, Optional pvarDefaultValue As Variant)
Dim fldX As DAO.Field
Dim intSize As Integer

Set fldX = ptdfTableDef.CreateField()

fldX.OrdinalPosition = ptdfTableDef.Fields.Count

fldX.Name = pstrFieldName
fldX.Type = pintDatatype

If Not IsMissing(pblnAllowZeroLength) Then
If pintDatatype = dbText And pintSize > 0 Then
fldX.Size = pintSize
Else
fldX.Size = GetFieldSize(pintDatatype)
End If
Else
fldX.Size = GetFieldSize(pintDatatype)
End If

If fldX.Type = dbLong Then
If pblnAutoIncrement = True Then
fldX.Attributes = fldX.Attributes Or dbAutoIncrField
End If
End If

If fldX.Type = dbText Or fldX.Type = dbMemo Then
fldX.AllowZeroLength = True
End If

If Not IsMissing(pblnRequired) Then
fldX.Required = pblnRequired
End If

If Not IsMissing(pstrValidationText) Then
fldX.ValidationText = pstrValidationText
End If

If Not IsMissing(pstrValidationRule) Then
fldX.ValidationRule = pstrValidationRule
End If

If Not IsMissing(pvarDefaultValue) Then
fldX.DefaultValue = pvarDefaultValue
End If

ptdfTableDef.Fields.Append fldX

End Sub
.

still i cannot get the transfer done
Mar 23 '07 #1
2 2101
vijaydiwakar
579 512MB
how can we transfer data from one access database to another databse . the table name is same for both the database . in one table some records are there (rs say e.g.) now another table has say rs+10 records . now i have to pass there 10 values to another table with same name . can anyone help me with this. i m usinf DAO
. i wrote some codes in dao. i created a function : AddTableField

i m writing it in module so that it can be access from anywhere in the program
this is the code

Sub AddTableField(ptdfTableDef As DAO.TableDef, pstrFieldName As String, pintDatatype As Integer, Optional pintSize As Integer, Optional pblnFixedLength As Boolean, Optional pblnAutoIncrement As Boolean, Optional pblnAllowZeroLength As Boolean, Optional pblnRequired As Boolean, Optional pstrValidationText As String, Optional pstrValidationRule As String, Optional pvarDefaultValue As Variant)
Dim fldX As DAO.Field
Dim intSize As Integer

Set fldX = ptdfTableDef.CreateField()

fldX.OrdinalPosition = ptdfTableDef.Fields.Count

fldX.Name = pstrFieldName
fldX.Type = pintDatatype

If Not IsMissing(pblnAllowZeroLength) Then
If pintDatatype = dbText And pintSize > 0 Then
fldX.Size = pintSize
Else
fldX.Size = GetFieldSize(pintDatatype)
End If
Else
fldX.Size = GetFieldSize(pintDatatype)
End If

If fldX.Type = dbLong Then
If pblnAutoIncrement = True Then
fldX.Attributes = fldX.Attributes Or dbAutoIncrField
End If
End If

If fldX.Type = dbText Or fldX.Type = dbMemo Then
fldX.AllowZeroLength = True
End If

If Not IsMissing(pblnRequired) Then
fldX.Required = pblnRequired
End If

If Not IsMissing(pstrValidationText) Then
fldX.ValidationText = pstrValidationText
End If

If Not IsMissing(pstrValidationRule) Then
fldX.ValidationRule = pstrValidationRule
End If

If Not IsMissing(pvarDefaultValue) Then
fldX.DefaultValue = pvarDefaultValue
End If

ptdfTableDef.Fields.Append fldX

End Sub
.

still i cannot get the transfer done
Dear try to use ADO
Mar 23 '07 #2
Can anybody make a programme to transfer data from one programme to another different programmes in c++ or dotnet or in java or in c or in cabol or in c-sharp

And retreive the same from other programmes as results

Data should be feed of more than 25,000 at one stroke in others different programmes.

send yr details at sanjaykumarnagar@gmail.com
call 9885292824
Dec 2 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: bwalke | last post by:
Hi all, I am fairly new to using triggers and was seeking some help from those that have experience with them. I am looking to transfer data from a SQL 2000 database to a Visual FoxPro database...
2
by: Travis Pupkin | last post by:
Hi, I made a copy of an Access 2000 database to do some dev work on it which involved fixing a few bad data types and adding a few columns to a couple of tables. Meanwhile the original...
4
by: Karl Irvin | last post by:
In a 2000, can you transfer custom menus and toolbars to a new Access database. My mdf file is not compiling and I'm importing all data to a new database but don't see a way to get the...
2
by: Andy Davis | last post by:
Has anybody tried and had any success exporting data directly from ACT! 2000 to an Access database? I need to transfer data from ACT! to Access, but the data is all imported as text, including date...
5
by: Tom | last post by:
Hi I am trying to transfer to a different .ASPX page using Server.Transfer. However, I get the following error: "Error executing child request for .aspx." Anyone know why? Thanks for...
5
by: mtgrizzly52 | last post by:
I am running an access 2003 dbase that has been slowly developed for use on a network. (I know, should be sql, but our IT dept won't allow that to happen, so we are stuck) Anyway, because of the...
4
by: evantay | last post by:
I'm using ASP.NET 2.0 with VS.NET 2005. I'm trying to access properties from my master pages within a page that inherits from that master page (a child page). However the values are always null....
5
by: jehugaleahsa | last post by:
Hello: What is the point of using a DataTable in ASP .NET? We are unsure how you can use them without 1) rebuilding them every postback, or 2) taking up precious memory. We are not sure how to...
1
by: janetopps | last post by:
I used a database transfer utility (Bullzip) to move data from Access to MySQL Asp pages, I couldn't transfer the data if i did not opt to leave the default values, therefore the default values...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.