Yes, Nt has a Translate Method that is used almost in every part of the Nt.
Then you have to go to the Translate method in the WebHandler, before the parencall and add some code like the following:
Returnvalue = p_string
TRA:TranslateFrom = p_string
get(Translate,TRA:XFROM)
if error() !traslate string not found then I add a record to the transaltion file (I use a TPS file)
if loc:Add=1 !getini('translation','add',1,'.\TRANSLAT.INI')=1
clear(tra:record)
TRA:TranslateFrom = p_string
!Trace('Adding Translate From: '&TRA:TranslateFrom)
TRA:ProcedureName = GlobalErrors.GetProcedureName()
Access:Translate.TryInsert()
end
ReturnValue = ''
else
if loc:Repair=1 !getini('translation','repair',0,'.\TRANSLAT.INI')=1
TRA:TranslateFrom = p_string
TRA:ProcedureName = GlobalErrors.GetProcedureName()
PUT(Translate)
END
ReturnValue = choose(p_web.gsv('LOGIN_lngCol')+1, TRA:TranslateTo_00, TRA:TranslateTo_01, TRA:TranslateTo_02, TRA:TranslateTo_03, TRA:TranslateTo_04, TRA:TranslateTo_05, TRA:TranslateTo_06, TRA:TranslateTo_07, TRA:TranslateTo_08, TRA:TranslateTo_09, TRA:TranslateTo_10, TRA:TranslateTo_11, TRA:TranslateTo_12, TRA:TranslateTo_13, TRA:TranslateTo_14, TRA:TranslateTo_15, TRA:TranslateTo_16, TRA:TranslateTo_17, TRA:TranslateTo_18, TRA:TranslateTo_19, TRA:TranslateTo_20)
!p_web.AddLog('Translate: '&p_String&' '&p_web.gsv('LOGIN_lngCol')&' '&clip(ReturnValue))
end
if ReturnValue = ''
ReturnValue = p_string
end
end
ReturnValue = parent.Translate(ReturnValue,p_AllowHtml)
Return clip(ReturnValue)