Solved

reading and writing files of type record where there is a header or trailer record

Posted on 2008-10-27
2
360 Views
Last Modified: 2010-04-05
How can I read or write files of type record where there is a header and or trailer record which has a different length and structure to the records in the body of the file?
0
Comment
Question by:alanjbrown
2 Comments
 
LVL 21

Expert Comment

by:developmentguru
ID: 22812387
Normally this is done in one of two ways.  XML will allow you to mix this sort of data but it is wildly inefficient.  If you want the speed of a database in what you are working on, this is normally achieved by writing the records to two different tables and loading them separately based on a common ID field.  If you have large volumes of data each data file is normally accompanied by an index (to speed the lookups).
0
 
LVL 28

Accepted Solution

by:
ciuly earned 250 total points
ID: 22815472
using the unit I gave you in the other question (for future reference: http://www.experts-exchange.com/Programming/Languages/Pascal/Delphi/Q_23848518.html ), you will be using the
OnBeforeConvertRecord
and
OnAfterConvertRecord
too read/write any data that is before and/or after the record.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now