Topic: Translate the buttons of the "Image in database" control

Hello everyone and thank you for reading my request.
I would have liked to translate the tooltip that appears on the buttons for inserting or removing a photo from the control for inserting photos.
I have read this thread: http://myvisualdatabase.com/forum/viewtopic.php?id=5402
and I really thought that here was the right procedure but it doesn't translate anything for me.

Translate('Open_image_to_save_the_database', 'Scegli un''immagine'' da aggiungere');
Translate('Export_image_from_database', 'Esporta immagine dal database');
Translate('Delete_Image', 'Elimina immagine');

Re: Translate the buttons of the "Image in database" control

Form1.DBImage1.ButtonOpen.Hint:= 'Scegli un''immagine'' da aggiungere';
Form1.DBImage1.ButtonSave.Hint:= 'Esporta immagine dal database';
Form1.DBImage1.ButtonDelete.Hint:= 'Elimina immagine';

Re: Translate the buttons of the "Image in database" control

Thank you very much Vladimir, perfect!

Re: Translate the buttons of the "Image in database" control

Is there the possibility of translating the menu that appears on click of the right mouse button, within a TabelGrid?

I tried trivially like this:

Translate('Copy_cell', 'Copia');

Unfortunately that would have been too good.

Re: Translate the buttons of the "Image in database" control

Hi Fabio, Hi Vladimir,
Try it like this (see attached).
Note that you can also choose to disable or hide any of the tablegrid right-click options (or hide or disable the right-click menu completely).
Derek.

Post's attachments

Attachment icon righclick on tablegrid.zip 439.06 kb, 138 downloads since 2023-05-04 

Re: Translate the buttons of the "Image in database" control

Hi Derek, your solution works as always, thanks! How to disable the menu, as you said?

Re: Translate the buttons of the "Image in database" control

Hi,
Just set the individual items to 'visible := false;'
See attached.
Derek.

Post's attachments

Attachment icon righclick on tablegrid2.zip 439.93 kb, 137 downloads since 2023-05-04 

8 (edited by k245 2023-05-05 08:46:52)

Re: Translate the buttons of the "Image in database" control

Hello! You may find the ideas on localization algorithms that I outlined in my article useful to you. In particular, there is an example of a localization system using text resource files. This solution does not require changing the program code when adding new interface objects for localization.


https://k245.ru/wp-content/uploads/2023/04/vybor-yazyka.png


https://k245.ru/en/mvdb-en/resources-an … ation.html


When you add a new language, you only need a new text file with translated resources.

Визуальное программирование: блог и телеграм-канал.

Re: Translate the buttons of the "Image in database" control

A couple of years ago, I even made a tool for localizing My Visual Database projects, but for some reason this topic was not particularly popular.

https://sites.google.com/view/multilang-1-0-en

Визуальное программирование: блог и телеграм-канал.

10 (edited by reteinformatica 2023-05-05 21:21:14)

Re: Translate the buttons of the "Image in database" control

Thanks derek and thanks to you too K245, I looked at the link and also the project but it's too advanced for me but maybe in part it answers a question I have in mind. Soon I will ask in the forum for a clarification to my doubts. Maybe one day I'll understand better, for now I'm following an online Pascal course.

Re: Translate the buttons of the "Image in database" control

HI k245, hi everyone,
I had a look at your project downloaded from the page you indicated. Unfortunately I can't see what it does in practice because I can't run it. When I run it I get this error: "Undeclared identifier 'labDesñription' at 311:25". And he puts my cursor at the 25:18 position basically a few spaces after the "end" command.
I thought that the identifier maybe should have been "labDscription" instead of "labDesñription" but I really don't know which file to find it on.

12 (edited by k245 2023-05-07 12:53:48)

Re: Translate the buttons of the "Image in database" control

reteinformatica wrote:

HI k245, hi everyone,
I had a look at your project downloaded from the page you indicated. Unfortunately I can't see what it does in practice because I can't run it. When I run it I get this error: "Undeclared identifier 'labDesñription' at 311:25". And he puts my cursor at the 25:18 position basically a few spaces after the "end" command.
I thought that the identifier maybe should have been "labDscription" instead of "labDesñription" but I really don't know which file to find it on.

I checked both links, everything is downloaded, ClassExplorer starts (MultiLang is installed) and does not contain errors.

http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=9418&download=0

Post's attachments

Attachment icon изображение_2023-05-07_155058103.png 212.98 kb, 66 downloads since 2023-05-07 

Визуальное программирование: блог и телеграм-канал.

Re: Translate the buttons of the "Image in database" control

Hi k245,
I tried downloading the project again from the page you linked.
The one in the attached screen shot is what happens to me when I run the project.

Post's attachments

Attachment icon Senza titolo.jpg 195.22 kb, 64 downloads since 2023-05-07 

14 (edited by k245 2023-05-08 18:13:32)

Re: Translate the buttons of the "Image in database" control

Well, I don’t know ... I downloaded the archive, unpacked it, launched it - everything works.There is a certainty that the matter is in different versions of the MVDB, but it is extremely small.

https://drive.google.com/file/d/1S2s0hZ … IELw4/view

http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=9432&download=0

Post's attachments

Attachment icon изображение_2023-05-08_211219238.png 159.38 kb, 54 downloads since 2023-05-08 

Визуальное программирование: блог и телеграм-канал.

Re: Translate the buttons of the "Image in database" control

Привет Константин, Fabio,
Просто для информации, но я получаю ту же ошибку при загрузке проекта (я использую Windows 10 с MVD 6.5).
Однако я изменил «Frmmain.labDescription» на Frmmain.derek  (не очень оригинально!) в форме «FrmMain, изменил сценарий «classexplorer.vdb», а также в «UserApp.pas» (строки 311, 312, 313), и это кажется, решить проблему.
Но почему он вообще жалуется — загадка.
Derek.
.
Just for information, but I'm getting the same error when loading a project (I'm using Windows 10 with MVD 6.5).
However I changed  'Frmmain.labDescription' to Frmmain.derek' (not very original!)in form 'FrmMain, changed the 'classexplorer.vdb' script and also in the 'UserApp.pas (lines 311, 312, 313) and this seems to fix the problem.
But why it complains in the first place is a puzzle.

Re: Translate the buttons of the "Image in database" control

derek wrote:

Привет Константин, Fabio,
Просто для информации, но я получаю ту же ошибку при загрузке проекта (я использую Windows 10 с MVD 6.5).
Однако я изменил «Frmmain.labDescription» на Frmmain.derek  (не очень оригинально!) в форме «FrmMain, изменил сценарий «classexplorer.vdb», а также в «UserApp.pas» (строки 311, 312, 313), и это кажется, решить проблему.
Но почему он вообще жалуется — загадка.
Derek.
.
Just for information, but I'm getting the same error when loading a project (I'm using Windows 10 with MVD 6.5).
However I changed  'Frmmain.labDescription' to Frmmain.derek' (not very original!)in form 'FrmMain, changed the 'classexplorer.vdb' script and also in the 'UserApp.pas (lines 311, 312, 313) and this seems to fix the problem.
But why it complains in the first place is a puzzle.

Yes, that allowed me to run the program. Thank you so much derek.

17 (edited by k245 2023-05-09 07:34:28)

Re: Translate the buttons of the "Image in database" control

The error was caused by the use of a Cyrillic character that is visually indistinguishable from the Latin

http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=9435&download=0

Thanks for the feedback, I'll fix it in the next version.

Post's attachments

Attachment icon изображение_2023-05-09_102826474.png 9.59 kb, 54 downloads since 2023-05-09 

Визуальное программирование: блог и телеграм-канал.