cancel
Showing results for 
Search instead for 
Did you mean: 

i18n Issue

Former Member
0 Kudos
509

Hello-

I have a issue with i18n text in my fragment view.

I have created a folder fragment and created a file called Export.fragment.xml. inside that I have 2 buttons as below one referring text from i18n and hard coded

But on the out put I cannot see the text I maintained in i18n :

exporttopdf = Export to PDF

exporttoexcel= Export to Excel

The out put shows blank on one button and

What should I do if I need to get i18n text to be reflected to my fragment folder?

Kindly help.

Thanks,

Karthik.

Accepted Solutions (1)

Accepted Solutions (1)

former_member82178
Active Participant
0 Kudos

We need to set i18n resource model explicitly for dialogfragment. check this link for example.

http://stackoverflow.com/questions/25636637/localizationi18n-in-sapui5-for-fragment-xml-file-in-not-...

Thanks,

Madhu Sudhan

Former Member
0 Kudos

Thanks Madhu it worked like a charm

Answers (4)

Answers (4)

sgodugu
Explorer
0 Kudos

Hi

Set the i18n model to _oPopover like 

this._oPopover.setModel( i18nModel, "i18n");

Regards

Sreenivas

fennercc
Employee
Employee
0 Kudos

Hi Karthikeyan,

start your app and open the fiori console (alt+shift+ctrl+s) and look for the menu with the missing label. If you select the control, is the text property filled?

There also is a UI5 Plugin for the Chrome browser that may help.

Sounds weird that one label is showing and another one not.

junwu
Active Contributor
0 Kudos

did u add this fragment as dependent of your view?

this.getView().addDependent(oDialogFragment);

Former Member
0 Kudos

Hi Jun,

Yes, that how I have called the popover below is the code.

jibin_joy
Contributor
0 Kudos

Hi Karthikeyan ,

  Based on the code u have shared it should work .Please put a debugger in first line of onPressPopOver  method and check the i18n model .

Regards,

Jibin Joy

jibin_joy
Contributor
0 Kudos

Hi Karthikeyan ,

Please share how u r creating i18n Model !!!

Regards,

Jibin Joy

Former Member
0 Kudos

Hi Jibin,

I am using normal SAP web IDE and created a new projected. It creates a initial view and i18n file automatically.

Thanks,

Karthik.

jibin_joy
Contributor
0 Kudos

HI Karthikeyan ,

We have to create resource  models also for more Information please Refer Step 8: Translatable Texts

Regards,

Jibin Joy

Former Member
0 Kudos

Hi Jibin,

As I said I have no issue in calling i18n translatable text on my views only on my fragment.

junwu
Active Contributor
0 Kudos

you can get the text in view not in fragment?