Foros Club Delphi

Foros Club Delphi (https://www.clubdelphi.com/foros/index.php)
-   Varios (https://www.clubdelphi.com/foros/forumdisplay.php?f=11)
-   -   Programa Multilenguaje (https://www.clubdelphi.com/foros/showthread.php?t=85827)

Edwardfeliz 12-05-2014 18:09:50

Programa Multilenguaje
 
Saludos a todos, me explico breve,

estuve buscando los diferentes metodos que hay y vi uno de Neftalí muy útil en Multiidioma

Pero me da un error al traducir algunos términos del programa, me explico cuando precioso el botón de traducir el programa me da un error.

Me da Error en un AdoQuery y me dice que no puede abrir el Dataset.

Saludos! ;)

duilioisola 12-05-2014 18:21:06

Eso debe ser porque habrás traducido algún nombre de campo o tabla de la base de datos.
Supongo que el error debe ser un poco más específico y te ayudará a saber cuál es exactamente.

Si utilizas la opción de GNUGettext deberás poner en tu aplicación que ignore ciertos componentes. Estos son algunos de los que utilizo en mis aplicaciones.

Código Delphi [-]
procedure InicializaIdioma;
begin
  // Add extra domain for runtime library translations
  AddDomainForResourceString('delphi');

  // Force program to use CATALA instead of the current Windows settings
  // UseLanguage ('ca');

   // Put ignores on the properties that cannot be translated
  TP_GlobalIgnoreClass(TDataSource);
  TP_GlobalIgnoreClass(TFont);
  TP_GlobalIgnoreClass(TParam);

  // FastReport
  TP_GlobalIgnoreClass(TfrDBDataSet);
[...]
  TP_GlobalIgnoreClassProperty(TForm, 'HelpFile');
  TP_IgnoreClassProperty(TWebBrowser, 'StatusText');

  TP_GlobalIgnoreClassProperty(TAction, 'Category');
  TP_GlobalIgnoreClassProperty(TControl, 'HelpKeyword');
[...]
  TP_GlobalIgnoreClassProperty(TFieldDef, 'Name');
  TP_GlobalIgnoreClassProperty(TColumn, 'FieldName');
[...]
  TP_GlobalIgnoreClassProperty(TDBComboBox, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBComboBox, 'Name');
  TP_GlobalIgnoreClassProperty(TDBCheckBox, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBCheckBox, 'Name');
  TP_GlobalIgnoreClassProperty(TDBEdit, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBEdit, 'Name');
  TP_GlobalIgnoreClassProperty(TDBImage, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBImage, 'Name');
  TP_GlobalIgnoreClassProperty(TDBListBox, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBListBox, 'Name');
  TP_GlobalIgnoreClassProperty(TDBLookupControl, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBLookupControl, 'KeyField');
  TP_GlobalIgnoreClassProperty(TDBLookupControl, 'ListField');
  TP_GlobalIgnoreClassProperty(TDBLookupControl, 'Name');
  TP_GlobalIgnoreClassProperty(TDBMemo, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBMemo, 'Name');
  TP_GlobalIgnoreClassProperty(TDBRadioGroup, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBRadioGroup, 'Name');
  TP_GlobalIgnoreClassProperty(TDBRadioGroup, 'Values');
  TP_GlobalIgnoreClassProperty(TDBRichEdit, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBRichEdit, 'Name');
  TP_GlobalIgnoreClassProperty(TDBText, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBText, 'Name');

  TP_GlobalIgnoreClassProperty(TDBComboBoxValue, 'DataField');
  TP_GlobalIgnoreClassProperty(TDBComboBoxValue, 'DataSource');
  TP_GlobalIgnoreClassProperty(TDBComboBoxValue, 'Name');
[...]
  TP_GlobalIgnoreClass(TFIBQuery);
  TP_GlobalIgnoreClass(TFIBTableSet);
  TP_GlobalIgnoreClass(TFIBDataSet);
[...]
  TP_GlobalIgnoreClass(TFIBQuery);
  TP_GlobalIgnoreClass(TFIBTableSet);
  TP_GlobalIgnoreClass(TFIBDataSet);
[...]
  TP_GlobalIgnoreClassProperty(TField, 'DefaultExpression');
  TP_GlobalIgnoreClassProperty(TField, 'FieldName');
  TP_GlobalIgnoreClassProperty(TField, 'KeyFields');
  TP_GlobalIgnoreClassProperty(TField, 'DisplayName');
  TP_GlobalIgnoreClassProperty(TField, 'LookupKeyFields');
  TP_GlobalIgnoreClassProperty(TField, 'LookupResultField');
  TP_GlobalIgnoreClassProperty(TField, 'Origin');
  TP_GlobalIgnoreClassProperty(TField, 'CustomConstraint');
  TP_GlobalIgnoreClassProperty(TField, 'ImportedConstraint');
  TP_GlobalIgnoreClassProperty(TField, 'ConstraintErrorMessage');
  TP_GlobalIgnoreClassProperty(TField, 'EditMask');
[...]


La franja horaria es GMT +2. Ahora son las 06:49:57.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi