Topic: How to click once on a table Grid cell to display the results in one .

How to click once on a table Grid cell to display the results in one or more cells in Memo

Post's attachments

Attachment icon example.png 110.01 kb, 63 downloads since 2024-08-23 

Re: How to click once on a table Grid cell to display the results in one .

So, it's actually multiple edit fields and not one memo field!

Post's attachments

Attachment icon get details.zip 518.17 kb, 125 downloads since 2024-08-23 

Re: How to click once on a table Grid cell to display the results in one .

That's what I wanted
thank you very much  Mr derek

Re: How to click once on a table Grid cell to display the results in one .

Sorry

Everything is good

But I had a problem adding the image in the previous example

Post's attachments

Attachment icon Example1.png 66.92 kb, 61 downloads since 2024-08-24 

Re: How to click once on a table Grid cell to display the results in one .

Hello Mouasomar, Hi Derek

1 - Add a DBImage (or a TImage) on Form1
2 - Add this code after the GetDetails procedure:

procedure get_details (Sender: TObject; MouseLeft, MouseRight, MouseMiddle: boolean; Shift, Alt, Ctrl: boolean; X, Y: Integer);
begin
......
.......
Form1.DBImage1.Clear;
Form1.DBImage1.LoadFromDatabase('YourTable', 'YourPicture', Form1.GridEmployees.dbItemID);
end;

JB

Re: How to click once on a table Grid cell to display the results in one .

Sorry jean.brezhonek, but the operation was unsuccessful.

Re: How to click once on a table Grid cell to display the results in one .

You need to add the image component in "Database tables"

Destiny

Re: How to click once on a table Grid cell to display the results in one .

Hi Mouasomar, Salut Jean et Destiny,
Jean's code is correct.
If you upload your application, we could see where your mistake is , otherwise it's just guess-work.
It should be something like this (see attached).
Derek.

Post's attachments

Attachment icon get details2.zip 878.09 kb, 109 downloads since 2024-08-24 

Re: How to click once on a table Grid cell to display the results in one .

The operation was successful.
Thank you very much Mr derek

10 (edited by mouasomar 2024-08-24 23:15:24)

Re: How to click once on a table Grid cell to display the results in one .

Hello
in this case how to write the code (emplsex)

Post's attachments

Attachment icon Example2.png 4.67 kb, 59 downloads since 2024-08-25 

Re: How to click once on a table Grid cell to display the results in one .

see attached

Post's attachments

Attachment icon get details3.zip 972.04 kb, 138 downloads since 2024-08-26 

Re: How to click once on a table Grid cell to display the results in one .

Thank you very very very very much Mr derek