PC Review


Reply
Thread Tools Rate Thread

Append method error

 
 
JonWayne
Guest
Posts: n/a
 
      4th Mar 2005
I use the following code snippet to create a table in an external database,
add 20 fields, and append the table to the tabledefs collection. The append
method fails with the message: Too many fields defined (3190). As you will
see, the table structure is identical to a table in the local database. Why
am I getting this message? Anyone pleeeeease help.

If RemoteTdf Is Nothing Then
Set RemoteTdf = RemoteDb.CreateTableDef(Tbl5)
RemoteDb.TableDefs.Refresh
Set LocalTdf = LocalDb.TableDefs(Tbl5)

For Each Fld In LocalTdf.Fields
Set Fld2 = RemoteTdf.CreateField(Fld.Name, Fld.Type)
If Fld.Type = dbText Then Fld2.Size = Fld.Size
RemoteTdf.Fields.Append Fld2
'x = x + 1
Next Fld

'MsgBox x
RemoteTdf.Connect = ";DATABASE=" & MainPath & Cty & "\" &
Cty & ".mdb;"
RemoteTdf.SourceTableName = Tbl5
RemoteDb.TableDefs.Append RemoteTdf
RemoteDb.TableDefs.Refresh
RemoteTdf.RefreshLink

ElseIf RemoteTdf.Connect = "" Then ....


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
append to front when using ColumnHistory method =?Utf-8?B?bWJheWN1cmE=?= Microsoft Access Form Coding 3 23rd Nov 2007 03:02 PM
ObjectDataSource & FormView adding two extra paramaters to Update method giving error non-generic method ... Fred Dag Microsoft ASP .NET 0 18th Sep 2006 11:36 PM
ObjectDataSource & FormView adding two extra paramaters to Update method giving error non-generic method ... Fred Dag Microsoft ADO .NET 0 18th Sep 2006 05:24 AM
Error trapping for "MS Access can't append all the records in the append query" Dale Microsoft Access VBA Modules 6 29th Dec 2004 02:27 AM
Append method? ThanhMai Microsoft Access VBA Modules 0 22nd Sep 2003 09:45 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:54 PM.