Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
15
Column variable name randomly changing in the designer - affects localization
posted

Hi,

In v10.3, we've been setting the caption (depending on the language selected) at runtime as suggested in one of the posts I've seen on this website.

Been thinking if we could ditch this way of doing things.

I am trying out v22.2 but the column name still changes randomly in the designer. In my case:

but the resulting change does not get updated in the resx file automatically :

Hence, my question, what is the best practice to localize ultragrids? Can we not just put the relevant caption in the language's resX file and let the magic be done by itself as is the case with other controls?

Changing the form language and inserting the captions is not really an option, since we are using the Multilingual App Toolkit to manage the translations. The captions get written over on each build.

Thanks,

Veevek

Parents
  • 7555
    Offline posted

    Hello Veevek,

    Thank you for contacting . In the WinGrid Columns keep on changing name in the designers file after reset the datasource is expected . It has a reason  , we cant restore the old name, as we are not using the old objects. The DataSource property is being reset which removes the existing UltraGridColumns and then assigned to the BindingSource again, which creates new UltraGridColumns. Since these are new columns and dont match the existing cached columns, the serializer must come up with new names for each column.

    Said that , in order to localize the grid column header you would have to give column some caption and use that caption as a resource string . and If the column.Header.Caption is blank (not set), then the control falls back to displaying the Key.

    Refer to this post discussing the same matter:

    https://es.infragistics.com/community/forums/f/ultimate-ui-for-windows-forms/69046/how-do-i-localize-bound-grid-headers

Reply Children