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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Topspeed Dynamic Link Libraries 1

Status
Not open for further replies.

argusy

Technical User
May 21, 2001
10
AU
We have a program commercially written using topspeed. Using the ODBC drivers was OK to extract data into Access until last week, when we now get an error."Internal error: tpsbt:cpp line 2172"
In the details - "MSACCESS caused an invalid page fault in module C40TRX.DLL....."
Access doesn't have a C40TRX.DLL.
Is this from Clarion/Topspeed?
 
Sorry, should check my 'O's and '0's (zeros) more often
 
I am not a programmer but a a help desk manager for a software company that uses Clarion to write our programs. That error you are seeing means that the Topspeed database you are trying to access your data from is corrupt. There is a utility called tpsfix.exe that will repair the database and keys. Just fixed one of those this morning. Hope this helps!
 
Hi!...

The best thing to do is install new version of Clarion 5 enterprises Edition. This is complete tool that will help you a lot in your problem.
 
hi ,

I had this error before try to us tpsfix.exe to rectify this error. It usually occurs when the concerned .dat file is corrupted. Follow the on screen details given while using tpsfix.exe.

Best Regards
Prem
 
friend
Where can i puchase an ODBC driver for clarion. if you have any, can i ask for a copy.
 
friend, is it possible for me to have a copy of an ODBC
driver for clarion coz i'm having a problem reading *.dat file.
 
The vendor sells topspeed (TPS) odbc drivers, there is not one for the clarion (DAT) files.
 
Please help me too gearhead.

I have a working MS Access\VBA program that I want to use the data from a clarion file. My normal method is to output a delimited file that I import into the necessary tables in MS Access. I have not found a way to do this that creates a clean file without any extra bad characters.

My next thought is that I would like to use an ODBC type of connection. The only problem is that the files are not a .TPS extension. It is a .DAT.

Can anyone help?

Thanks in advance.

Spencer
 
As long as the data files are not "Owner encrypted" your only real option is to create an export program that will "dump" the data to CSV. If you need someone to do this work I know there are Clarion developers on this board, or you can have the vendor create an export routine for you.
HTH
 
Hi all,

Please could someone help me before I lose my mind... For info I have no experience of Clarion or TopSpeed.

I too am having problems linking an Access2000 database to what I think is a Clarion database. I have been sent files that have the extension of .DAT which I am told are Clarion database files. Having spoken to people at SoftVelocity and their respective international partners in both Australia and the UK I was led to believe that I could access these files using the ODBC drivers which I then purchased.

Having installed the drivers it is obvious that they expect files with the .TPS extension. Judging by Gearhead's reply above you cannot use ODBC to Clarion despite what SoftVelocity told me.

I am therefore confused. Are TopSpeed and Clarion two different database systems? If that is so are they both made by SoftVelocity? I am puzzled as to why SoftVelocity sell ODBC drivers for TopSpeed when their web site advertises Clarion.

Lastly (for now!) am I correct to assume that if the files are "Owner encrypted" then we will effectively be locked out of the data through security in the ODBC and if they are not "Owner encrypted" then is it simple for someone to make them "Owner encrypted" and lock me out after doing my ODBC work?

Why are things never simple???

If anyone can help with any of this then your help will be much appreciated.

Matt Terroni, UK
 
Matt,
If the data files have a TPS extension then they are Topspeed format data files. If they have a DAT then they are most likely Clarion DAT format files. In both cases the data file extensions can be user (programmer) defined so it becomes a bit tricky. Also in both cases if an Owner attribute has been used during the creation of the files then you must know this string (password). Lastly there is only an ODBC driver available for the Topspeed TPS format data files. And if this is not enough the TPS files can be "compound" files and contain more than a single table definition. And (are you nervous yet?) if a GROUP structure has been used in the file declararion then a command like "SELECT * FROM XYZ" will most likely blow up.

So to recap general rules would be:
1 - Only TPS files can be accessed via ODBC (TPS ODBC Driver)

2 - Check with your software application providor for the Owner string (if applicable)

3 - Try to get a table definition to make select statements actually work easier

4 - Know the DATE/TIME columns (and set them up in the ODBC administrator) so that the driver translates the standard Clarion Date/Time to something everyone else can understand.

5 - Try to use the TPS ODBC driver for read only operations (this reduces the need for too much No. 6)

6 - Have a beer and chill or else this stuff will get you pulling your hair.

As far as you purchasing the TPS ODBC driver and being told it would work for DAT files, the company is very resonable and I'm certain they will work through the misunderstanding with you.

HTH







 
Hi Gearhead,

Thanks very much for your help. I still have a couple of questions though!

To start with, I wondered why you mentioned the date/time fields in Clarion. Are these stored as some magical information only known to the inner workings of the Clarion database? I took a quick look at one of the .DAT files and where the date/time is expected I cannot see anything meaningful, not even a number or anything.

I am now looking to write a binary import routine within MSAccess to read the data from the .DAT files directly into my MSAccess database. I've tried this for one of the files and it appears to work okay. I'll have to work out the definitions etc but the raw data tables appear to be fixed length records with a chunk of header information for the field names etc. Do you know if this is correct and if so do you see any problems with what I am proposing to do.

Lastly, I am still unclear as to the relationship between TopSpeed and Clarion. How are these products related and are they both database systems?

Thanks again for your help. It's really appreciated.

Bye

Matt Terroni, UK
 
Matt,
Housekeeping first; Clarion is a language, development system, data file format (DAT), and the name of the originating company (actually it had 1 earlier name but it doesn't matter). TopSpeed is the name of a company that was a merger result of Jensen and Partners International (TopSpeed compilers) from the UK and Clarion Software from the US. The TopSpeed file format (TPS) is also an ISAM data file.

Collectively all things Clarion and TopSpeed (software not developers/companies) are owned by a completely new company; SoftVelocity.

Date/Time fields are magic in Clarion! Actually they are stored in standard Clarion Date and Clarion Time formats.

Standard Date: Elapsed days since December 28, 1800. The range of accessible dates is from January 1, 1801 (standard date 4) to December 31, 9999 (standard date 2,994,626)

Standard Time: Elasped 100th/sec since midnight The range is 1 (defined as midnight) to 8,640,000 (defined as 11:59:59.99 PM)

Now to the disappointing bit, the Clarion DAT file format has actually been published (no I can't locate it). The format has changed at least once and they are incompatible. Your basic premise is correct that there is a header block and it describes the layout, width and quantity of records. If the file has been Owner encrypted you won't be able to tell much in clear text. The task you are embarking on is not impossible just very difficult.

Is this a one time deal or are you looking to access the data on a continuing basis?

HTH









 
Gearhead,

Thanks for taking the time to reply again, appreciate it.

I've been analysing one of the .DAT files and have been able to read most of the data. The one thing I'm having problems with are the dates and times which I was expecting. The format of the date and time is not a problem as MSAccess works in a similar way. However, I cannot see any obvious corrolation between the data in the file and a date.

I believe the date and time are stored in two four byte fields but cannot determine how to calculate this into an actual date. Do you happen to know this?

Thanks for all your help.

Matt Terroni, UK
 
Date and Time are generally stored in LONG datatypes which are four byte signed. The formula to calculate the date and time is in my previous post. eg 71531 is 01 NOV 1996

HTH
 
Thanks Gearhead for your help with this. I've managed to import the .DAT files into MSAccess now by writing my own code to read the header information and then analyse the data within the files. It's not perfect yet by any stretch of the imagination but I'm getting there. You helped me a lot and just wanted to say thanks.

So, thanks :)

Bye

Matt Terroni, UK
 
gearhead,

maybe you can help me, i'm not a programmer i just run a computer store, i had someonbe program me a file with with an extension *.tps, i used to vie wthat file using TopScan, but one of my ex-workers, put a passwords on it, nd now i cn't get it my database, how can i rmeove the password, please help me
 
The encryption algorithm has not been published for the TPS files. There are several techniques to "discover" what the pw may be. The only way to pw protect files after they are created it to use the development system and "convert" the files physically to a new structure (which includes the pw information). This means you would need the development system to do so. If you do have the development system then the pw is available there. If you do not and your co-worker did not then the TPS files are most likely not pw protected. If you provide more detail we can "get to the bottom of it".

HTH
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top