 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Charlie Guest
|
Posted: Thu Mar 29, 2007 4:28 am Post subject: DoubleClick a DBGrid Row |
|
|
Hi, I'm using Delphi 5cs, dBase files.
I want to be able to double click a row in a dbGrid and pass the record to
components in another form. Specifically the dbGrid's records are fields
from the orders table. I'd like to find a particular order in the grid,
double click and open a form where I can view and/or edit the order.
Thank you,
Charlie |
|
| Back to top |
|
 |
Robin Guest
|
Posted: Mon May 21, 2007 8:12 am Post subject: Re: DoubleClick a DBGrid Row |
|
|
Charlie wrote:
| Quote: | Hi, I'm using Delphi 5cs, dBase files.
I want to be able to double click a row in a dbGrid and pass the record to
components in another form. Specifically the dbGrid's records are fields
from the orders table. I'd like to find a particular order in the grid,
double click and open a form where I can view and/or edit the order.
Thank you,
Charlie
|
Hi Charlie,
When you click on the row, (single or double) you have selected that row
in the underlying dataset (table?).
This means you can reference the dataset/table directly. Like this:
Table1.FieldByName('MyField').AsString;
You see, in data-aware components like the DBGrid, when you select a row
the dataset underneath follows and also selects that row. Makes your
life nice and easy.
--
Robin.
Australian Bridal Accessories := http://www.bridalbuzz.com.au
Turbo for Noobs (a work in progress) := http://turbofornoobs.blogspot.com/ |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|