|
View:
New views
7 Messages
—
Rating Filter:
Alert me
|
|
|
HowTo change DataGrid NavigationLabelHi list!
I'm trying to change the default NavigationLabel for the inMethod DataGrid. the documentation says : The message can be overridden using the |NavigatorLabel| property key, the default message is used is of the format |Showing ${from} to ${to} of ${of}|. The message can also be configured pragmatically by setting it as the model object of the label. But I don't get how this is meant. Can anyone provide some example code how to change the default text? Regards Oliver --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
|
|
Re: HowTo change DataGrid NavigationLabelDo not use inMethod (nice) data grid myself but from what I understand from
your message you could either -Subclass the grid to a MyDataGrid, add a MyDataGrid_lang.properties and, e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last property file. -If you only want this for a page, say MyPage, add a MyPage_lang.properties and do the same as in previous step. Hope this works Regards, Ernesto On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@...>wrote: > Hi list! > > I'm trying to change the default NavigationLabel for the inMethod DataGrid. > the documentation says : > > The message can be overridden using the |NavigatorLabel| property key, the > default message is used is of the format |Showing ${from} to ${to} of > ${of}|. The message can also be configured pragmatically by setting it as > the model object of the label. > But I don't get how this is meant. Can anyone provide some example code how > to change the default text? > > Regards > Oliver > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@... > For additional commands, e-mail: users-help@... > > |
|
|
Re: HowTo change DataGrid NavigationLabelThanks for your reply!
Problem is that the message "Showing..." is hard coded into the NavigationLabel.class so property files won't affect it. Regards, Oliver > Do not use inMethod (nice) data grid myself but from what I understand from > your message you could either > > -Subclass the grid to a MyDataGrid, add a MyDataGrid_lang.properties and, > e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last > property file. > -If you only want this for a page, say MyPage, add a MyPage_lang.properties > and do the same as in previous step. > > Hope this works > > Regards, > > Ernesto > > On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@...>wrote: > > >> Hi list! >> >> I'm trying to change the default NavigationLabel for the inMethod DataGrid. >> the documentation says : >> >> The message can be overridden using the |NavigatorLabel| property key, the >> default message is used is of the format |Showing ${from} to ${to} of >> ${of}|. The message can also be configured pragmatically by setting it as >> the model object of the label. >> But I don't get how this is meant. Can anyone provide some example code how >> to change the default text? >> >> Regards >> Oliver >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscribe@... >> For additional commands, e-mail: users-help@... >> >> >> --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
|
|
Re: HowTo change DataGrid NavigationLabelIs this NavigationLabel part of the GRID classes? I see a NavigatorLabel?
and the code is like public NavigatorLabel(final String id, final DataGrid table) { super(id); setDefaultModel(new StringResourceModel("NavigatorLabel", this, new Model(new LabelModelObject(table)), "Showing ${from} to ${to} of ${of}")); } So the "Showing ${from} to ${to} of ${of}" will only appear as a default value if no resource "NavigatorLabel" can be found on the resources. Try what I said and (I guess) that will work. Regards, Ernesto On Thu, Nov 5, 2009 at 11:57 AM, Oliver-Sven Fritsch <osf@...>wrote: > Thanks for your reply! > > Problem is that the message "Showing..." is hard coded into the > NavigationLabel.class so property files won't affect it. > > Regards, > > Oliver > > > Do not use inMethod (nice) data grid myself but from what I understand >> from >> your message you could either >> >> -Subclass the grid to a MyDataGrid, add a MyDataGrid_lang.properties and, >> e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last >> property file. >> -If you only want this for a page, say MyPage, add a >> MyPage_lang.properties >> and do the same as in previous step. >> >> Hope this works >> >> Regards, >> >> Ernesto >> >> On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@... >> >wrote: >> >> >> >>> Hi list! >>> >>> I'm trying to change the default NavigationLabel for the inMethod >>> DataGrid. >>> the documentation says : >>> >>> The message can be overridden using the |NavigatorLabel| property key, >>> the >>> default message is used is of the format |Showing ${from} to ${to} of >>> ${of}|. The message can also be configured pragmatically by setting it as >>> the model object of the label. >>> But I don't get how this is meant. Can anyone provide some example code >>> how >>> to change the default text? >>> >>> Regards >>> Oliver >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@... >>> For additional commands, e-mail: users-help@... >>> >>> >>> >>> >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@... > For additional commands, e-mail: users-help@... > > |
|
|
Re: HowTo change DataGrid NavigationLabelI've added
NavigatorLabel=XXX to the global properties files of my app and it works like a charm. (I wanted to internationalise the label.) Regards, Linda Ernesto Reinaldo Barreiro wrote: > Is this NavigationLabel part of the GRID classes? I see a NavigatorLabel? > and the code is like > > public NavigatorLabel(final String id, final DataGrid table) { > super(id); > setDefaultModel(new StringResourceModel("NavigatorLabel", this, new > Model(new LabelModelObject(table)), > "Showing ${from} to ${to} of ${of}")); > } > > So the "Showing ${from} to ${to} of ${of}" will only appear as a default > value if no resource "NavigatorLabel" can be found on the resources. Try > what I said and (I guess) that will work. > > Regards, > > Ernesto > > > On Thu, Nov 5, 2009 at 11:57 AM, Oliver-Sven Fritsch <osf@...>wrote: > > >> Thanks for your reply! >> >> Problem is that the message "Showing..." is hard coded into the >> NavigationLabel.class so property files won't affect it. >> >> Regards, >> >> Oliver >> >> >> Do not use inMethod (nice) data grid myself but from what I understand >> >>> from >>> your message you could either >>> >>> -Subclass the grid to a MyDataGrid, add a MyDataGrid_lang.properties and, >>> e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last >>> property file. >>> -If you only want this for a page, say MyPage, add a >>> MyPage_lang.properties >>> and do the same as in previous step. >>> >>> Hope this works >>> >>> Regards, >>> >>> Ernesto >>> >>> On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@... >>> >>>> wrote: >>>> >>> >>> >>>> Hi list! >>>> >>>> I'm trying to change the default NavigationLabel for the inMethod >>>> DataGrid. >>>> the documentation says : >>>> >>>> The message can be overridden using the |NavigatorLabel| property key, >>>> the >>>> default message is used is of the format |Showing ${from} to ${to} of >>>> ${of}|. The message can also be configured pragmatically by setting it as >>>> the model object of the label. >>>> But I don't get how this is meant. Can anyone provide some example code >>>> how >>>> to change the default text? >>>> >>>> Regards >>>> Oliver >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: users-unsubscribe@... >>>> For additional commands, e-mail: users-help@... >>>> >>>> >>>> >>>> >>>> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscribe@... >> For additional commands, e-mail: users-help@... >> >> >> > > > ------------------------------------------------------------------------ > > > Geen virus gevonden in het binnenkomende-bericht. > Gecontroleerd door AVG - www.avg.com > Versie: 9.0.698 / Virusdatabase: 270.14.50/2481 - datum van uitgifte: 11/04/09 20:51:00 > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
|
|
Re: HowTo change DataGrid NavigationLabelYes, that will, for sure, set the same label for the whole application.
Creating a sub-class is a better option, IMHO, if you want to use the same component at several applications... Best, Ernesto On Thu, Nov 5, 2009 at 12:33 PM, Linda van der Pal < lvdpal@...> wrote: > I've added > > NavigatorLabel=XXX > > to the global properties files of my app and it works like a charm. (I > wanted to internationalise the label.) > > Regards, > Linda > > Ernesto Reinaldo Barreiro wrote: > >> Is this NavigationLabel part of the GRID classes? I see a NavigatorLabel? >> and the code is like >> >> public NavigatorLabel(final String id, final DataGrid table) { >> super(id); >> setDefaultModel(new StringResourceModel("NavigatorLabel", this, new >> Model(new LabelModelObject(table)), >> "Showing ${from} to ${to} of ${of}")); >> } >> >> So the "Showing ${from} to ${to} of ${of}" will only appear as a default >> value if no resource "NavigatorLabel" can be found on the resources. Try >> what I said and (I guess) that will work. >> >> Regards, >> >> Ernesto >> >> >> On Thu, Nov 5, 2009 at 11:57 AM, Oliver-Sven Fritsch <osf@... >> >wrote: >> >> >> >>> Thanks for your reply! >>> >>> Problem is that the message "Showing..." is hard coded into the >>> NavigationLabel.class so property files won't affect it. >>> >>> Regards, >>> >>> Oliver >>> >>> >>> Do not use inMethod (nice) data grid myself but from what I understand >>> >>> >>>> from >>>> your message you could either >>>> >>>> -Subclass the grid to a MyDataGrid, add a MyDataGrid_lang.properties >>>> and, >>>> e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last >>>> property file. >>>> -If you only want this for a page, say MyPage, add a >>>> MyPage_lang.properties >>>> and do the same as in previous step. >>>> >>>> Hope this works >>>> >>>> Regards, >>>> >>>> Ernesto >>>> >>>> On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@... >>>> >>>> >>>>> wrote: >>>>> >>>>> >>>> >>>> >>>> >>>>> Hi list! >>>>> >>>>> I'm trying to change the default NavigationLabel for the inMethod >>>>> DataGrid. >>>>> the documentation says : >>>>> >>>>> The message can be overridden using the |NavigatorLabel| property key, >>>>> the >>>>> default message is used is of the format |Showing ${from} to ${to} of >>>>> ${of}|. The message can also be configured pragmatically by setting it >>>>> as >>>>> the model object of the label. >>>>> But I don't get how this is meant. Can anyone provide some example code >>>>> how >>>>> to change the default text? >>>>> >>>>> Regards >>>>> Oliver >>>>> >>>>> --------------------------------------------------------------------- >>>>> To unsubscribe, e-mail: users-unsubscribe@... >>>>> For additional commands, e-mail: users-help@... >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@... >>> For additional commands, e-mail: users-help@... >>> >>> >>> >>> >> >> ------------------------------------------------------------------------ >> >> >> Geen virus gevonden in het binnenkomende-bericht. >> Gecontroleerd door AVG - www.avg.com Versie: 9.0.698 / Virusdatabase: >> 270.14.50/2481 - datum van uitgifte: 11/04/09 20:51:00 >> >> >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@... > For additional commands, e-mail: users-help@... > > |
|
|
Re: HowTo change DataGrid NavigationLabelThanks!
That finally did the trick. :-) Regards, Oliver Linda van der Pal schrieb: > I've added > > NavigatorLabel=XXX > > to the global properties files of my app and it works like a charm. (I > wanted to internationalise the label.) > > Regards, > Linda > > Ernesto Reinaldo Barreiro wrote: >> Is this NavigationLabel part of the GRID classes? I see a >> NavigatorLabel? >> and the code is like >> >> public NavigatorLabel(final String id, final DataGrid table) { >> super(id); >> setDefaultModel(new StringResourceModel("NavigatorLabel", this, new >> Model(new LabelModelObject(table)), >> "Showing ${from} to ${to} of ${of}")); >> } >> >> So the "Showing ${from} to ${to} of ${of}" will only appear as a default >> value if no resource "NavigatorLabel" can be found on the resources. Try >> what I said and (I guess) that will work. >> >> Regards, >> >> Ernesto >> >> >> On Thu, Nov 5, 2009 at 11:57 AM, Oliver-Sven Fritsch >> <osf@...>wrote: >> >> >>> Thanks for your reply! >>> >>> Problem is that the message "Showing..." is hard coded into the >>> NavigationLabel.class so property files won't affect it. >>> >>> Regards, >>> >>> Oliver >>> >>> >>> Do not use inMethod (nice) data grid myself but from what I understand >>> >>>> from >>>> your message you could either >>>> >>>> -Subclass the grid to a MyDataGrid, add a >>>> MyDataGrid_lang.properties and, >>>> e.g. add a NavigatorLabel = Paginas ${from} to ${to} of ${of} to last >>>> property file. >>>> -If you only want this for a page, say MyPage, add a >>>> MyPage_lang.properties >>>> and do the same as in previous step. >>>> >>>> Hope this works >>>> >>>> Regards, >>>> >>>> Ernesto >>>> >>>> On Thu, Nov 5, 2009 at 11:36 AM, Oliver-Sven Fritsch <osf@... >>>> >>>>> wrote: >>>>> >>>> >>>> >>>>> Hi list! >>>>> >>>>> I'm trying to change the default NavigationLabel for the inMethod >>>>> DataGrid. >>>>> the documentation says : >>>>> >>>>> The message can be overridden using the |NavigatorLabel| property >>>>> key, >>>>> the >>>>> default message is used is of the format |Showing ${from} to ${to} of >>>>> ${of}|. The message can also be configured pragmatically by >>>>> setting it as >>>>> the model object of the label. >>>>> But I don't get how this is meant. Can anyone provide some example >>>>> code >>>>> how >>>>> to change the default text? >>>>> >>>>> Regards >>>>> Oliver >>>>> >>>>> --------------------------------------------------------------------- >>>>> To unsubscribe, e-mail: users-unsubscribe@... >>>>> For additional commands, e-mail: users-help@... >>>>> >>>>> >>>>> >>>>> >>>>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@... >>> For additional commands, e-mail: users-help@... >>> >>> >>> >> >> >> ------------------------------------------------------------------------ >> >> >> Geen virus gevonden in het binnenkomende-bericht. >> Gecontroleerd door AVG - www.avg.com Versie: 9.0.698 / Virusdatabase: >> 270.14.50/2481 - datum van uitgifte: 11/04/09 20:51:00 >> >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@... > For additional commands, e-mail: users-help@... > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
| Free embeddable forum powered by Nabble | Forum Help |