home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.pascal
- Path: sparky!uunet!mcsun!sun4nl!utrcu1!infnews!infnews!waardenb
- From: waardenb@cs.utwente.nl (Jerry van Waardenberg)
- Subject: RE: I need help with copying ""records""
- Message-ID: <1992Sep9.102443@cs.utwente.nl>
- Sender: usenet@cs.utwente.nl
- Nntp-Posting-Host: utis107
- Organization: University of Twente, Dept. of Computer Science
- References: <1992Sep07.162555.5226@crash> <9SEP92.01244365@skyfox.usask.ca>
- Date: Wed, 9 Sep 1992 08:24:43 GMT
- Lines: 29
-
- In article <9SEP92.01244365@skyfox.usask.ca>, friesenda@skyfox.usask.ca writes:
- |> In a previous article, tech@crash.cts.com (Don Bontemps) wrote:
- |>
- |> >Now if I wanted to copy data[1] to data [2], could I just say
- |> >data[2] := data[1] or would I have to do it this way
- |> >data[2].name := data[1].name and so on and so forth. Your help
- |> >would be greatly appreciated. Thanks (in advance).
- |>
- |>
- |> data[2] := data[1];
- |>
- |> should work fine; both elements are of the same type. Its the
- |> same as assigning one integer to another - just a different variable
- |> type.
- |>
-
- In Turbo Pascal, you can also use the move command to copy blocks of data:
-
- Move(Data[1], Data[2], SizeOf(Data[2]));
-
- I use the SizeOf(Data[2])) expression for safety reasons.
-
-
- Jerry van Waardenberg ______ ____ _____ _____
- Tele Informatics and Open Systems / / / / /_
- Department of Computer Science / / / / -_
- University of Twente, Enschede, The Netherlands / __/_ /____/ _____/
- E-mail: waardenb@cs.utwente.nl
-
-