Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data Transfer not working

Status
Not open for further replies.

woodyinoz

IS-IT--Management
Jan 8, 2002
215
GB
Hi all,

I am trying to use a tCursor to append some information onto another table.

The code I am using can be seen below:

dthandle.SetSource ("Bolt Import.db")
if dthandle.getSourceType ( ) = DTASCIIFixed Then
dthandle.loadDestSpec ( "SpecTable" )
endIf
dthandle.setDest ( "Bolt Import1.db" )
if not dthandle.getAppend ( ) then
dthandle.setAppend ( True )
endif

dthandle.transferData ( )


Bolt Import.db is a table that is created under the same button through a query, whilst Bolt import1.db is a table that always exists.

The code does not bring up any errors but it does not seem to be doing anything at all. I have used this code countless times before and it has worked and if I place it under a button of its own it also works but it does not work under the current button which contains other code.

Any help would be appreciated,

Thanks,

Woody.
 
Woody,

Since it works elsewhere, I suspect there's another error interfering. Unfortunately, I don't see any immediate problems in the snippet you posted, so I suspect there's an environmental facotr involved.

Try the following:

1. First, make certain that the Developer menus are enabled. Choose Tools | Settings | Developer Preferences, select the General tab, and then place a checkmark in the Show Developer menus option.

2. Next, open your form in Design mode and then the Program menu to enable both Compiler Warnings and Compile with Debug.

3. At the top of the event this code is taken from, add the following line of code:

Code:
errorTrapOnWarnings( Yes )

This will change the severity of any error to a critical and display it in a dialog box. In addition, the debugging information should give you specific information about the line of code where the error was detected.

I know this is a little lean on specifics, but I think it's a troubleshooting question at this point and this should help you nail down the actual problem.

Hope it does...

-- Lance
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top