Topic: How to translate interface and messages
How to translate interface and messages
begin
// how to translate interface
Form1.mniFile.Caption := 'File';
Form1.mniClose.Caption := 'Close';
Form1.mniOptions.Caption := 'Options';
Form1.mniSettings.Caption := 'Settings';
Form1.mniReport.Caption := 'Report designer';
Form1.mniExportData.Caption := 'Export data';
Form1.mniImportData.Caption := 'Import data';
Form1.mniAbout.Caption := 'About';
frmOptionsdbCore.Caption := 'Options';
frmOptionsdbCore.TabDatabaseLoc.Caption := 'Database location';
frmOptionsdbCore.rbAppFolder.Caption := 'Save the database file in the folder with the application.';
frmOptionsdbCore.rbDBFilename.Caption := 'Specify the filename of the database.';
frmOptionsdbCore.lbPath.Caption := 'You can also use a network folder (e.d. \\PCNAME\Folder\sqlite.db)';
frmOptionsdbCore.bCancel.Caption := 'Cancel';
frmOptionsdbCore.TabSettings.Caption := 'Settings';
frmOptionsdbCore.GroupBoxSettings.Caption := 'Configuration file (settings.ini)';
frmOptionsdbCore.rbSettingsIniApp.Caption := 'Save the configuration file in the folder with application.';
frmOptionsdbCore.rbSettingsIniAppData.Caption := 'Save the configuration file in the folder:'+#13+'%appdata%\My Visual Database Configurations\%projectname%';
frmdbCoreImport.Caption := 'Import';
frmdbCoreImport.gbFileAndSettings.Caption := '1. File and settings';
frmdbCoreImport.lbFile.Caption := 'CSV file name';
frmdbCoreImport.lbColumnsSeparator.Caption := 'Columns separator';
frmdbCoreImport.cbSeparator.Items[0] := ', (comma)';
frmdbCoreImport.cbSeparator.Items[1] := '; (semicolon) ';
frmdbCoreImport.cbSeparator.Items[2] := '\t (tab)';
frmdbCoreImport.cbSeparator.Items[3] := 'Custom';
frmdbCoreImport.cbSeparator.ItemIndex := 0;
frmdbCoreImport.lbEncoding.Caption := 'Encoding';
frmdbCoreImport.chbColumnNamesRow.Caption := 'Column name as first row';
frmdbCoreImport.lbDateFormat.Caption := 'Date format';
frmdbCoreImport.cbDateFormat.Items[0] := 'SQL format';
frmdbCoreImport.cbDateFormat.Items[1] := 'Regional format ';
frmdbCoreImport.lbTimeFormat.Caption := 'Time format';
frmdbCoreImport.cbTimeFormat.Items[0] := 'SQL format';
frmdbCoreImport.cbTimeFormat.Items[1] := 'Regional format ';
frmdbCoreImport.gbData.Caption := '2. Data';
frmdbCoreImport.lbImportTable.Caption := 'The table for import';
frmdbCoreImport.lbFieldsAndColumns.Caption := 'Specify field name for every column';
frmdbCoreImport.lbSqliteWarning.Caption := 'Backup your database before importing.'+#13+'The database may be damaged if you turn off the computer during import.';
frmdbCoreImport.bImport.Caption := 'Import';
frmdbCoreExport.Caption := 'Export';
TdbStringGridEx(frmdbCoreExport.gridTables).Columns[0].Header.Caption := 'Tables';
TdbStringGridEx(frmdbCoreExport.gridFields).Columns[1].Header.Caption := 'Fields';
frmdbCoreExport.lbSettings.Caption := 'Settings';
frmdbCoreExport.chbColumnNamesRow.Caption := 'Column name as first row';
frmdbCoreExport.lbColumnsSeparator.Caption := 'Columns separator';
frmdbCoreExport.cbSeparator.Items[0] := ', (comma)';
frmdbCoreExport.cbSeparator.Items[1] := '; (semicolon) ';
frmdbCoreExport.cbSeparator.Items[2] := '\t (tab)';
frmdbCoreExport.cbSeparator.Items[3] := 'Custom';
frmdbCoreExport.cbSeparator.ItemIndex := 0;
frmdbCoreExport.lbEndOfLine.Caption := 'End of line';
frmdbCoreExport.chbEnclosing.Caption := 'Double quotes enclose';
frmdbCoreExport.lbSQLFilter.Caption := 'SQL filter (WHERE conditions)';
frmdbCoreExport.bExport.Caption := 'Export to CSV';
frmdbCoreImportProgress.Caption := 'Importing...';
frmdbCoreImportProgress.bMore.Caption := 'More details';
frmdbCoreImportProgress.bCancel.Caption := 'Cancel';
// how to translate messages and captions
Translate('Open_report_designer', 'Open report designer');
Translate('Your_computer_does_not_have_Excel', 'Your computer does not have Excel');
Translate('Your_computer_does_not_have_LibreOffice', 'Your computer does not have LibreOffice');
Translate('Your_computer_does_not_have_Excel_or_LibreOffice', 'Your computer does not have Excel or LibreOffice');
Translate('Entry_to_edit_is_no_selected', 'Entry to edit is no selected');
Translate('Unable to determine the record ID', 'Unable_to_determine_the_record_ID');
Translate('Please_select_record_in_grid', 'Please select record in grid');
Translate('Report_file_not_found', 'Report file not found');
Translate('Entry_to_be_deleted_is_not_selected', 'Entry to be deleted is not selected');
Translate('Are_you_sure_you_want_to_delete_the_record', 'Are you sure you want to delete the record');
Translate('The_database_file_is_not_found', 'The database file is not found');
Translate('Not_a_number: string', 'Not a number');
Translate('Are_you_sure_you_want_to_delete_the_image_from_the_database', 'Are you sure you want to delete the image from the database');
Translate('There_is_no_file_to_save', 'There is no file to save');
Translate('Do_you_really_want_to_delete_the_file_from_the_database', 'Do you really want to delete the file from the database');
Translate('Restart_the_program_to_apply_the_settings', 'Restart the program to apply the settings');
Translate('This_Field_is_required', 'This Field is required');
Translate('Not_permitted_to_use_ComboBox_for_saving_record', 'Not permitted to use ComboBox for saving record');
Translate('Saving_or_opening_file_from_database', 'Saving or opening file from database');
Translate('Select_file_stored_in_database', 'Select file stored in database');
Translate('Export_image_from_database', 'Export image from database');
Translate('Open_image_to_save_the_database', 'Open image to save the database');
Translate('Delete_Image', 'Delete Image');
Translate('Calculated_field', 'Calculated field');
Translate('Counter_field', 'Counter field');
Translate('Open_file', 'Open file');
Translate('Save_file', 'Save file');
Translate('Delete_file', 'Delete file');
Translate('Open_folder_with_file', 'Open folder with file');
Translate('Clear', 'Clear');
Translate('Open', 'Open');
Translate('Component', 'Component');
Translate('No_data_to_add', 'No data to add');
Translate('File_not_found', 'File not found');
Translate('Confirm', 'Confirm');
Translate('Error', 'Error');
Translate('Info', 'Info');
Translate('Set_marker', 'Set marker');
Translate('Set_marker_at_address', 'Set marker at address');
Translate('Delete_marker', 'Delete marker');
Translate('Address', 'Address');
Translate('Export', 'Export');
Translate('Import', 'Import');
Translate('Records_exported', 'Records exported');
Translate('Records_imported', 'Records imported');
Translate('Export_is_not_configured_correctly', 'Export is not configured correctly.');
Translate('Import_is_not_configured_correctly', 'Import is not configured correctly.');
Translate('Yes', 'Ja');
Translate('No', 'Nein');
Translate('None', 'None');
Translate('Skip', 'Skip');
Translate('Close', 'Close');
Translate('Cancel', 'Cancel');
end.
Project example:
http://myvisualdatabase.com/forum/misc. … download=1