Accessing XFStrings through Business Rules
Does anyone know if it's possible to access XFStrings through Business Rules? We are adding other languages to our application and we are using XFStrings for Cube Views and Dashboards. We want to present our custom BR error messages in the user's chosen language so we thought XFStrings would be a good place to keep them. However we don't know if it's possible and if it is possible, how to do it. We are currently using Transformation Rules for some other areas but we want to have a single place where the translations can be managed.
Thanks
Hi hiren
I needed to change your code a little bit but I have got it working. And you only need one Dashboard parameter. I changed the parameter default value from
XFString(Dummy, Culture=|!Culture!|)
to
XFString(|!XFstr!|, Culture=|!Culture!|)
Then I changed the Rules to this :
Dim params As New Dictionary(Of String, String) From {{"Culture", "fr-FR"}, {"XFStr", "str_Currency"}} Dim ParamDisplayInfo As DashboardParamDisplayInfo = BRApi.Dashboards.Parameters.GetParameterDisplayInfo(si, False, params, "Param_Dummy") brapi.ErrorLog.LogMessage(si, ParamDisplayInfo.DefaultValueAfterSubstitution)
Note that there are only 4 params - GUID.empty is removed - and the parameter name does not take the dashboard name. This might be a difference in versions.
So the Rules pass through the XFString name as well as the Culture code. Works beautifully. Thank you so much for your help.