Showing application message with different languages...
Hi guys,
i've a question for you.
I'm trying to add to my jsf application a new language.
I've added a resource bundle and everythings it's ok.
My question is:
if in my bean i've
if (rs.next()) {
FacesContext facesContext = FacesContext
.getCurrentInstance();
facesContext.addMessage(null, new FacesMessage(
FacesMessage.SEVERITY_ERROR,
"Il laboratorio risulta essere gi� inserito",
"Laboratorio esistente"));
}that print a message in a language,how can i this message in the other language(english,for example)?
I have to put also application message into resource bundle?
How can i retrieve them?
Please help me...
thanks very much,
i've changed english as default in th locale but nothing!!!
i retrieve only italian messages...
can you help me to find the error?
When i pass to english mode all outputText messages of application became in english,but application message of bean are in italian,i try to print locale and it is
it
Here is my code of my visit object,it is of session type
package giu;
import java.io.Serializable;
import java.sql.Connection;
import java.sql.Statement;
import java.util.*;
import javax.faces.application.Application;
import javax.faces.context.FacesContext;
import javax.faces.model.SelectItem;
import javax.servlet.http.HttpSessionBindingEvent;
import javax.servlet.http.HttpSessionBindingListener;
import javax.sql.DataSource;
public class Visit implements HttpSessionBindingListener {
private static final long serialVersionUID = 1L;
* @uml.property name="user"
* @uml.associationEnd
private User user;
* @uml.property name="localeItems"
private boolean loggedIn;
private List localeItems;
public static Connection conn;
* @uml.property name="authenticationBean"
* @uml.associationEnd
private AuthenticationBean authenticationBean;
public Visit() {
* @return Returns the user.
* @uml.property name="user"
public User getUser() {
return user;
* @param user
* The user to set.
* @uml.property name="user"
public void setUser(User user) {
this.user = user;
public boolean getLoggedIn() {
return loggedIn;
* @param user
* The user to set.
* @uml.property name="user"
public void setLoggedIn(boolean loggedIn) {
this.loggedIn = loggedIn;
* @return Returns the authenticationBean.
* @uml.property name="authenticationBean"
public AuthenticationBean getAuthenticationBean() {
return authenticationBean;
* @param authenticationBean
* The authenticationBean to set.
* @uml.property name="authenticationBean"
public void setAuthenticationBean(AuthenticationBean authenticationBean) {
this.authenticationBean = authenticationBean;
public List getSupportedtLocaleItems()
if (localeItems == null)
localeItems = new ArrayList();
Application app = FacesContext.getCurrentInstance().getApplication();
for (Iterator i = app.getSupportedLocales(); i.hasNext(); )
Locale locale = (Locale)i.next();
SelectItem item = new SelectItem(locale.toString(), locale.getDisplayName());
localeItems.add(item);
if (localeItems.size() == 0)
Locale defaultLocale = app.getDefaultLocale();
localeItems.add(new SelectItem(defaultLocale.toString(), defaultLocale.getDisplayName()));
return localeItems;
public String getLocale()
return FacesContext.getCurrentInstance().getViewRoot().getLocale().toString();
public void setLocale(String locale)
FacesContext.getCurrentInstance().getViewRoot().setLocale(new Locale(locale));
}and this is the header of my jsf pages
<h:selectOneListbox id="languageSelect" size="1" styleClass="language-select" value="#{visit.locale}">
<f:selectItems value="#{visit.supportedtLocaleItems}"/>
</h:selectOneListbox>
<h:commandButton value="Go!" styleClass="language-select-button"/>and this is my web.xml
<application>
<message-bundle>microarray.bundle.messageResource</message-bundle>
<locale-config>
<default-locale>it</default-locale>
<supported-locale>it</supported-locale>
<supported-locale>en</supported-locale>
</locale-config>
</application>can someone help me?
Thanks
Similar Messages
-
Is it possible to work with different languages in different applications?
Hi,
is it possible to work with different languages in different applications?
To have f.e. Photoshop in English and Indesign in Dutch??
Thanks!I am not sure about it that you can use different apps in different language in the same computer, however you can check the following links:
http://helpx.adobe.com/creative-cloud/kb/change-installed-language.html
Adjust the install language | CCM
http://tv.adobe.com/watch/learn-creative-cloud/installing-multiple-languages-of-a-desktop- application/
Regards
Rajshree -
Show error message with multilingual in ADF Jdeveloper 10g 10.1.2
Hi
I want show error message with multilingual in my application, but i don't know how to do.
Can you give me some solution.
I live in vietnamese.
Thank a lot.When i using code
ResourceBundle bundle = ResourceBundle.getBundle("MyResources",Locale.ENGLISH);
String key = "hello";
String s = bundle.getString(key); // Hello
key = "bye";
s = bundle.getString(key); // Goodbye
then there is error follow
java.util.MissingResourceException: Can't find bundle for base name MyResources, locale en
at java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:804)
at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:773)
at java.util.ResourceBundle.getBundle(ResourceBundle.java:538)
at mypackage1.Application1.main(Application1.java:21)
Can you show where error or you have some code about that issue, you can show me -
How to display the entire application in two different languages in apex
Hi,
How to display the entire application in two different languages in apex...
For example i need to display each item in both English and Hindi..
To achieve this initially i have the select the language otherwise the item label alone ll be displayed in both languages ...
Anyhow how it ll be apex is it possible
Regards,
PavanHi pars,
http://www.packtpub.com/sites/default/files/1346-chapter-6-creating-multilingual-apex-applications.pdf?utm_source=packtp…
In this link also i struck in
In page 10 of that document
The application is now ready to be translated. Everything is in place to run it in any language imaginable.To ca ll the application in another language, change the URL of your application to the following:
http://yourdomain:port/pls/apex/f?p=&APP_ID.:&PAGE_ID.:&SESSION_ID.:LANG:NO::FSP_LANGUAGE_PREFERENCE:nl
This example will call the chosen page in the application and show it in the Dutch language instead of in English. To select another language change the property nl at the end of the URL to your desired language code.
Thanks alot for ur suggestions.kindly provide more inputs.............. -
I finished my movied. and then tried to move everything into a new file labeled TAJE files. Now when I try to open the last version of the movie, I get nothing but 2 of the title clips and then every clip is a red one with different languages saying something about media off line? I deleted old copies but thought that was ok?
PamYes, if you have a completed DVD and just want to copy it then use disk burning software, not PRE. I use Nero and ImgBurn as my main burning applications - Nero is commercial, ImgBurn is free.
If you want to make extra copies over time you would be better to copy the VIDEO_TS folder from your DVD to your Hard Disk and then point ImgBurn at the folder.
For new projects requiring multiple DVDs to be burnt you would be better during Share to burn it to disk. Again, once it's there you can just point ImgBurn at it.
Cheers,
Neale
Insanity is hereditary, you get it from your children -
How to install Virtual Keyboard with Different language ?
HI,
How to install Virtual Keyboard with Different language (Arabic) in MacBook Pro ( Mac OS X v10.5.8 Leopard).
Thanks,How to install Virtual Keyboard with Different language (Arabic) in MacBook Pro ( Mac OS X v10.5.8 Leopard).
What are you talking about exactly?
OS X comes with a virtual keyboard already. It is called Keyboard Viewer. You activate it by going to system prefs/international/input menu and checking its box (plus the box for Show Input Menu in Finder). At the same time you can check the boxes for the Arabic keyboard layouts.
You can then select the Arabic keyboard layouts and the Keyboard Viewer from the "flag" menu at the top-right of the Finder.
Let us know if you have further questions. If you are talking about some specific non-Apple app, could you provide the url? -
Acrobat XI downloaded with different language
I mistakenly downloaded Adobe Acrobat Professional XI Pro with different language that I cannot understand. I want to change the language to English. Kindly note that the downloading was already finished. Please help.
You may be able to change the language in Preferences.
-
A region with different language
I want to use a region Dominican republic with different language not in spanish. but in english??? how do i put it back
yes but when y put english in the languege and put dominican rep in fortmat it only has dominican rep (in spanish) an i want it in english for formats
Perhaps it would help if you would explain exactly how you want your computer to behave. What exactly do you want to be in English? What do you want to relate to the DR? -
My email Box show blank messages with date 31/12/00.This bug passed my 3GS to 4S.How can i fix this?
My email Box show blank messages with date 31/12/00.This bug passed my 3GS to 4S.How can i fix this?
-
Parsing XML file with different languages (Xerces)
How do we code or program to an XML file with different
languages , say english and spanish. WHen we parse such a document with the default locale , the presence of special characters throws errors .For eg when I use xerces and use
DOMParser parser = new DOMParser();
try
// Parse the XML Document
parser.parse(xmlFile);
catch (SAXException se)
se.printStackTrace();
org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0xfc) was found in the element content of the document.
System Error: void org.apache.xerces.framework.XMLParser.parse(org.xml.sax.InputSource)
So what locale do we set before we parse ?How to handle this problemYou need an encoding attribute in the xml declaration. If you don't, the parser assumes UTF-8, which are ASCII characters up to 127 - useful (only) for English.
So, something like this would allow you to use characters above 127, ISO-8859-1 is the encoding used by standard PCs.
<?xml version="1.0" encoding="ISO-8859-1"?>
You can find a (offical) list of encodings at:
http://www.iana.org/assignments/character-sets
I'm not sure about mixing various encodings. I think you have to resort external parsed entities, which can have their own encoding, but I think you cannot mix encodings in one XML file.
Good luck. -
Show email information with diferent language correctly
hi
I have an web site that create with pl/sql server page script.
This web site inclue forms that user can search from information
of library books.
One of facility of this program is email page that can email
some of informations of books that user select during search.
my problem is:
my tables in database include some data with diferent languages
that when this information send by page_mail application
in receiver mailbox doesn't show correctly just english data
show correctly .could I ask you to send me a message to see for myself?
Presumably "Bcc:" me and "To:" yourself would demonstrate the effect.
xenos at gmx dot co dot uk -
Java Cache Viewer shows duplicate URL with different versions
In doing some testing lately we have come across a couple of situations where the same URL is showing in the JAVA cache viewer with different versions to them. In the case of a 1.7 JRE this is not causing any adverse effects however when utilizing a 1.6 JRE we are getting messages about mixed mode for the JAR files.
The jar file is signed as below:
Manifest-Version: 1.0
Ant-Version: Apache Ant 1.8.2
Application-Library-Allowable-Codebase: *
Application-Name: named_applet
Built-By: relbuild
Permissions: all-permissions
Created-By: 1.6.0_17-b04 (Sun Microsystems Inc.)
Caller-Allowable-Codebase: *
Codebase: *
understanding the need to change the wildcard's to domains as we move forward. I am wondering why the jar file is being listed and called twice and why it is being recognized as signed one time and not the next.
The URL is identical in the cache viewer and the java console says it is not found in the cache when it is used the second time, even though previously in the session is finds it with the correct version.
Any advice would be helpfulthat i even know, but the problem is that i do not have that version of java re installed, but i found distribution 07 of the same java version, i'll try it out with that.
but when it still doesn't work, then i still would like to find the link where i can download java version 1.4.2_06. -
Video with different language audiotracks
Hi,
do someone know a way to solve this problem:
I want to produce a video for an mobile app, which comes with three different languages.
The aim is, that there shall be one video and three different language audiotracks in the app. When the user chooses his language, the video shall play with his chosen language track. When he chooses another language, the same video shall play with the other language.
So, the videofile and the audiotracks exist independently in the app. I want NOT to put three complete versions of the video in the app, but only one videofile which shall be combined in runtime with the audio, after the user chooses his language.
Maybe there is a way...
Thanks
MarkusHi Markus,
In Captivate 6 we have an option in the On Success Actions to "Play Audio",
So you can have just one video and three audio tracks, and 3 buttons which on click plays the corresponding audio..
If you dont have Captivate 6, then you might have to associate each audio to an object (say highlight box with transparency) and then hide or show the object when you click on the button,
Please let me know if you want more detailed steps on this..
regards,
Hari -
I can't type with different language?
I'm trying to insert a text into my video in different language, but for some reason, it shows up as a box with "X" mark on it
do I need to download a language pack?
help please! thank you!If this is what you are getting:
then you have chosen a font that PrE's Titler cannot display properly. This was a Kozuka font (free version).
Also, many Multi-national fonts will not display properly, and will default their display to Times or Arial. I have found many, that neither PS, nor Titler, can properly display, even if they are well-written. When that happens, I often opt for doing the work in Adobe Illustrator, then Placing the AI document into a Photoshop Custom Image, that matches my Project, letting PS Rasterize the Image.
Good luck,
Hunt -
Script with different language
Heloo all,
I have a form in EN, I want the same form in Japan language JA.
It should support the following condition:
1. If i login in JA, for example TEXT window show some text in JA or other what i maintained.
2. If I login in EN, then the same TEXT window show some differen text which i maitained.
Form name should be same in above casess.
Plz let me know how to achive the above requirmet for single form.
Plz provide steps to achive this.
Thanks in advance.
Regards,Hi Sandya,
for copying the standard script into csutome script follow this steps
In transaction SE71 goto Utilities -> Copy from client -> Give source form name, source client (000 default), Target form name.
Open the custom form with DE language clcik on change button.
save+ activate.
Now
Press F3(back)
Nad give the same form name and opne it in JA langauge
Click on change and save + activate.
Regards,
Pravin
Maybe you are looking for
-
How to create Exchange dynamic distribution list using multivalue extension custom attribute
I am trying to create a dynamic distribution list using an ExtensionCustomAttribute. I am in hybrid mode with Exchange 2013. The syntax I have is this: New-DynamicDistributionGroup -Name "DG_NH" -RecipientFilter {(ExtensionCustomAttribute2 -eq 'NH
-
Hi everyone: I just can't find the <s:Module>, is there any chance to use <s:state> and <s:transitions> in <mx:module> It is very strange.. thanks
-
imported a drum track from bin to arrange area. It will not follow tempo of the project even though it was recorded in this project. The 'follow tempo' box in the inspector does not appear even though it is present on other tracks in the file. how
-
Sold to Party from Ship to Party
Hi, We have a requirement that when creating a service order, we need the sold to party to be determined when the ship to party is entered. Can someone pls tell how this can be achieved Points will be given Prachi
-
Hi name is gabriel h I purchase some coins in the apps kick the body and I buy 8.00 dollars and they don't purchase that they purchase 80.00 and I'm not happy wath they do now I erase they app from my phone and my iPod and they still charging I need