Avoid automatic resource bundle creation in JDeveloper?

Hi! I have a question.
My application consists of few modules - jar files. One module "Translations" is designed to supply the application with translations that are extracted from a database. So that module contains List resource bundle as a java class, let's call it DBbundle.java. The problem is when I try to use this bundle in other modules. When I set that DBbundle should be the label translations supplier for view objects in some other module, JDeveloper automatically creates that DBbundle in that same workspace, though I import "Translations" module in that workspace. I also set Project properties -> Resource bundle on a project to use DBbundle (from "Translations" module) and uncheck "Automatically Synchronize Bundle", "Warn About Hard-coded Translatable Strings" and "Always Prompt for Description" checkboxes.
So every time I edit a view, JDeveloper automatically creates DBbundle in that project. This is very annoying "feature". Does anyone know how to avoid this kind of behaviour?
This is how I set bundle on view objects
<ResourceBundle>
        <JavaResourceBundle
            MsgBundleClass="framework.translations.resources.DBbundle"/>
</ResourceBundle>
The same goes for Project properties -> Resource bundle
Please, anyone?
I use JDeveloper 11.1.2.3.0.

Please, no one knows?

Similar Messages

  • How to set text resources avoiding automatic page update with c:set tag

    Hello everyone,
    I'm developing my web application with JDeveloper 11.1.2.3.0 in order to support two language locales (en and de). Following this guide I've performed the following steps:
    Creation of two property files (Resources.properties and Resources_de.properties) with the key-value entries;
    Modify of faces-config.xml file adding these lines:
    <locale-config>
            <default-locale>en</default-locale>
            <supported-locale>de</supported-locale>
      </locale-config>
      <resource-bundle>
          <base-name>view.Resources</base-name>
          <var>res</var>
       </resource-bundle>
    In the project properties > Resources Bundle I've checked:
    Automatically Synchronize Bundle;
    Warn about Hard-coed Translatable Strings;
    Always Prompt for Description.
    In the same place I've set the default project bundle name to view.Resources.
    In a test JSP page I've a outputText with the value #{res['HELLOWORLD']} where HELLOWORLD is the key in the property files. All works fine, and the correct string is shown based on locale browser settings.
    Anyway, when I use the "Select Text Resources..." menu in any text value choosing a value from the default property file, JDev automatically adds the following tag:
    <c:set var="customuiBundle" value="#{adfBundle['view.ViewControllerBundle']}"/>
    setting the value of the text in #{ViewControllerBundle.HELLOWORLD}.
    There is a way to avoid this behavior? Can I manage the resources in a different way? I would to choose a value from the list in order to get the res.KEY value instead of ViewControllerBundle.KEY value.
    Thanks in advance for your help.
    Manuel

    don't select from menu - go to source and write it . The problem with the tools is they have a certain way of doing things and don't think we should spend time customizing jdeveloper rather concentrate on the work in hand.

  • Mini-bug : JDeveloper 10.1.3 resource bundles

    Hello,
    Here's a mini-bug in the resource bundles for JDeveloper 10.1.3. In the Dynamic List binding wizard (the one that you use to make a list of value from databindings), in the list binding section there's a typo : "soruce" instead of "source".
    This evil bug has no workaround ! Run around screaming
    Seriously, this little typo won't hurt anything or anyone, but I just wanted to report it nonetheless.
    Regards,
    Simon Lessard
    Message was edited by:
    Simon Lessard
    Edit: Had a typo in the subject, was a tad annoying considering what this post is about.

    Hello,
    Here's a mini-bug in the resource bundles for JDeveloper 10.1.3. In the Dynamic List binding wizard (the one that you use to make a list of value from databindings), in the list binding section there's a typo : "soruce" instead of "source".
    This evil bug has no workaround ! Run around screaming
    Seriously, this little typo won't hurt anything or anyone, but I just wanted to report it nonetheless.
    Regards,
    Simon Lessard
    Message was edited by:
    Simon Lessard
    Edit: Had a typo in the subject, was a tad annoying considering what this post is about.

  • Resource bundle naming issue across platforms

    Sorry, but there's no issue anymore. After a complete restart of the windows server it now accepts lowercase "da".
    We're using resource bundles to internationalize our app for English and Danish users. The default resource bundle is named "ViewControllerBundle" and the Danish bundle is named "ViewControllerBundle_DA" (on windows at least).
    Our problem occurs, when we deploy the application on different platforms. At the moment we have Weblogic 10.3.5 running on Linux and on Windows. Our development environment (JDeveloper 11.1.2) is running on Windows.
    When we deploy the application on Weblogic/Linux we need to rename the Danish resource bundle to lowercase "da", like "ViewControllerBundle_da".
    When we deploy on Windows or runs the application from JDeveloper we need to name the Danish resource bundle with uppercase "DA", like "ViewControllerBundle_DA".
    If we don't rename the bundles we're not able to display danish labels etc.
    I would like to know, whether we are naming the bundle the right way or whether it is possible to avoid this manual renaming before deploy. We would like to use the same EAR file for all the servers, if possible.
    From faces-config:
    <locale-config>
    <default-locale>da_DK</default-locale>
    <supported-locale>da_DK</supported-locale>
    <supported-locale>en_GB</supported-locale>
    </locale-config>
    Edited by: wmjaboj on 2011-08-30 02:45

    b) In some parts on our website, we need to show data, depending on an attribute in a user's profile. So, for instance, if the user is not an administrator, the address shouldn't be shown when his profile is shown to a regular user. Is there an elegant way to solve this? I'm a Struts programmer (first JSF project) and normally you do <c:if test="${}">, but that's not possible in JSF :-).You can certainly use JSTL in JSF. You need at least JSF 1.2 at a JSP 2.1 environment and JSTL 1.2. Google for "unified EL" in Sun.com. But if you want to use a JSF-only solution, then make use of the 'rendered' attribute which is supported by every JSF HTML component and a few JSF core components. It accepts a boolean expression and when it evaluates to true, then the component will be rendered in the view.
    E.g.<h:panelGroup rendered="#{user.admin}">
        <h:outputText value="I am an admin." />
    </h:panelGroup>where the User bean look likepublic class User {
        public boolean isAdmin() {
            return admin;
    }Here are some more EL examples which you can use in the 'rendered' attribute:<h:someComponent rendered="#{myBean.booleanValue}" />
    <h:someComponent rendered="#{!myBean.booleanValue}" />
    <h:someComponent rendered="#{myBean.intValue > 10}" />
    <h:someComponent rendered="#{myBean.objectValue == null}" />
    <h:someComponent rendered="#{myBean.stringValue != 'someValue'}" />
    <h:someComponent rendered="#{!empty myBean.collectionValue}" />
    <h:someComponent rendered="#{!myBean.booleanValue && myBean.intValue != 0}" />
    <h:someComponent rendered="#{myBean.stringValue == 'oneValue' || myBean.stringValue == 'anotherValue'}" />

  • How to deal with resource bundle in multiple applications system

    Hi all,
    I'm building new system depend on the method of
    one common model with multiple applications for the view objects
    my JDeveloper version 11.1.2.3
    my Question
    How can i merge the resource bundle for these applications
    as in the common model exists file for resouce bundle
    and each other applications contains resource bundle files how can i merge all these file in one Resource bundle file ?
    Edited by: 985756 on Apr 2, 2013 12:39 AM

    Hi,
    Please check anerjusb blog for your answer
    Hoping this will help you.
    http://andrejusb.blogspot.in/2009/12/reusing-resource-bundles-from-different.html
    Thanks & Regards,
    Vikas

  • Problem using Resource Bundle in XSLT File

    Hi All,
    I've been trying to use Resource Bundle on my XSLT file with no success for the last 2 weeks. So I would like some help to definitely end this problem.
    The fact is that i have a property file that i would like to read and it works fine when i use jsp or a servlet however when i try to call the same property file using my XSL i get the message below:
    java.util.MissingResourceException: Can't find bundle for base name thoth, locale en_US
    Follow the code from my Stylesheet that i'm calling the resource bundle:
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:java="java.util.ResourceBundle" exclude-result-prefixes="java" version="1.0">
    <xsl:strip-space elements="*"/>
    <xsl:output method="html" indent="yes" version="4.0"/>
    <xsl:output encoding="ISO-8859-1"/>
    <xsl:template match="page">
    <html>
    <body>
    <xsl:apply-templates select="paragraph"/>
    <xsl:variable name="resources" select="java:getBundle('thoth')"/>
    <xsl:value-of select="java:getString($resources,'general.title')"/>
    </body>
    </html>
    </xsl:template>
    </xsl:stylesheet>
    Please someone could help me why this file cannot be located, I am 100% of sure the property file path is in my classpath since it works fine in a servlet. Should i have to put it some other place? Do i have some other way to read this file and show the information from the file?
    I would appreciate any help
    thanks in advance and Regards
    Fabio

    Please someone could help me why this file cannot be located, I am 100% of sure the property file path is in my classpath since it works fine in a servlet.
    Is the property file in your classpath? or whether the directory where the property file is residing is in your classpath. Please put only the directory where the property file is located in the classpath and try again.
    It may be working fine with the servlet because j2ee servlet containers put the classes and lib directory automatically in the classpath therefore resource bundle gets loaded even without putting it explicitly in the classpath. This doesn't happen when you try to test some component from the console.
    Let me know if this does not work.
    regards,
    Abhishek.

  • Automate the EAR creation and deployment process

    Hi,
    I am trying to automate the EAR creation and deployment process. I am following this approach - http://www.oracle.com/technetwork/articles/adf/part4-098813.html
    In this approach we use pure ANT without OJDeploy. I am able to Create the EAR file but while deploying to weblogic server manually I get the attached error.
    Error is - java.lang.ClassNotFoundException: javax.faces.webapp.FacesServlet
    I would like to know, Is this the best practise to automate the EAR Creation and Deployment Process? If not, Please provide me some other best approach.
    Thanks in Advance.
    Regards
    Balaji S

    Balaji,
    I am the author of that article.
    At the time I wrote the article, ojdeploy was not working properly - however, the bugs that I noted at the time have been fixed. If I were writing the article today, my strong recommendation would be to use ojdeploy.
    If you insist to use the pure ANT (no ojdeploy) approach, I'd debug your issue this way:
    1). Generate the EAR file using the deploy option from the application navigator in JDeveloper. Deploy that EAR file to your WLS server and test to ensure it works. A note that if you are creating an ADF app, you must deploy the JRF to WLS first.
    2). Once the EAR from JDev is working, use a tool such as WinZip to expand the JDeveloper-generated EAR file and your ANT-generated EAR file. Compare the two. If you find differences, fix the ANT scripts so that they are the same.
    John

  • Error : An error occurred while automatically activating bundle org.eclipse

    Hi,
    OpenScript closed with unsaved changes and now I cannot get it to open again. I checked out the logs it was giving the below error.
    !ENTRY org.eclipse.core.resources 2 10035 2013-03-28 10:05:18.046
    !MESSAGE The workspace exited with unsaved changes in the previous session; refreshing workspace to recover changes.
    !ENTRY org.eclipse.osgi 4 0 2013-03-28 10:05:18.062
    !MESSAGE An error occurred while automatically activating bundle org.eclipse.core.resources (326).
    !STACK 0
    org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start() of bundle org.eclipse.core.resources.
    I do not mind losing the file with the unsaved changes. Please let me know if anyone has faced a similar problem and the solution for the same.
    Thanks!

    Hi,
    OpenScript closed with unsaved changes and now I cannot get it to open again. I checked out the logs it was giving the below error.
    !ENTRY org.eclipse.core.resources 2 10035 2013-03-28 10:05:18.046
    !MESSAGE The workspace exited with unsaved changes in the previous session; refreshing workspace to recover changes.
    !ENTRY org.eclipse.osgi 4 0 2013-03-28 10:05:18.062
    !MESSAGE An error occurred while automatically activating bundle org.eclipse.core.resources (326).
    !STACK 0
    org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start() of bundle org.eclipse.core.resources.
    I do not mind losing the file with the unsaved changes. Please let me know if anyone has faced a similar problem and the solution for the same.
    Thanks!

  • ADF:  Translated XLIFF Resource Bundle not Selected at Runtime

    Issue: When I run my ADF app in a web browser where French is selected as the default language, the labels on the form are still populated with English text from the default resource bundle, even though an XLIFF resource bundle for French exists.
    Details: I have created a default XLIFF resource bundle containing the text for all labels on my form in English, called labels.xlf. I have also created two translated XLIFF bundles for French and German and named them labels_fr.xlf and labels_de.xlf, respectively.
    On my form, I have used value expressions to retrieve the text for each component's label, like label="#{res.language}. JDeveloper added '<c:set var="res" value="#{adfBundle['oracle.fosxliff.uitest.labels']}"/>' to the top of my page, so I could access the resource bundle text. Identifying the resource bundle in the faces-config.xml file does not work. However, I did define which locales are supported by my application in this config file.
    *NOTE:* When I access these sames resource bundles in a managed bean by utilizing the locale of the UIViewRoot, the correct XLIFF file is retrieved and the translated text is correctly assigned to my components on the form.
    Is there some other configuration that I am missing? I was expecting XLIFF files to work similarly to properties files, which do work correctly regardless of whether the text is accessed using value expressions or managed beans.

    Ok, I've found the answer.
    I've added translatable custom properties on the view implemention
    and access these in the code...

  • Is there a way to 'reload' a Resource Bundle?

    Dear All,
    Use Case:
    I confgured a bundle in my faces-config.xml
    <resource-bundle>
      <base-name>com.test.MyBundle</base-name>
      <var>myBundle</var>
    </resource-bundle>..and my Bundle class loads data from a database table. So instead of using properties file, I saved the labels in a table
    using this code.
    public class MyBundle extends ListResourceBundle {
        public Object[][] getContents() {
              Object[][] resource;
            ResourceLabels lView = ADFBCUtil.getAppModule().getResourceLabelViews();
                   More codes
            return resource;
    }Now here goes my problem... supposed somebody changed the label in the DB table and wanted that to reflect to the new label.
    Is there a way to re-initialize my bundle?
    What happens is that, I need to restart the application so that it would read the table again. As I notice, the ADF app reads this
    bundle only once during startup
    Any Hints. Thanks.
    JDEV 11G 11.1.1.5

    vinod_t_krishnan wrote:
    why cant you do this.. operation in the button click.. so that the binding or the underlying objects gets updated..
    ADFBCUtil.getAppModule().getResourceLabelViews();
    Hi Vinod,
    That isn't what I am trying to do. Let me try to explain my use case again.
    1. I configured a Resources bundle in faces-config.xml
    2. When my application starts, it reads the configured bundle.
    3. Since I configured my bundle to load contents from database, it will query my table once during startup. The list of labels/messages are now in my bundle.
    4. User change something in my label(s) table and he/she want's it to be displayed automatically in the UI
    5. So he/she should be able to reload/reinitialize my bundle. This is where I am having trouble
    I am thinking of having an ADMIN screen where there is a button to click that will reload/reinitialize my bundle.
    But my problem is how do I tell my ADF app to reload the bundle again?
    A quick alternative is to restart my application since this will read the resource bundle again during startup. But this is not what I wanted.

  • Skin resource bundle

    Hi,
    I'm using a paged af:table and getting in the logs "<RenderingContext> <getTranslatedString> Could not fetch resource key Page from the skin myskin.desktop" (roughly translated).
    Solution in non-portal application is to specify resource bundle with specified key in trinidad-skins.xml/skins/skin/bundle-name but what is the proper solution in a portal application if I still want to allow for runtime selection of skin?
    The "update portal resource" dialog does not provide input of resource bundle name.
    The generated generic-site-resources.xml contains a reference resourceBundle="oracle.webcenter.framework.translations.TranslationsMDSResourceBundle" that indicates there might be some proper place to put skin bundle resources. (I tried editing the xml manually testing changing resourceBundle="MyBundle" and also adding <customAttribute name="skinBundleName" seeded="false" value="MyBundle" visible="ALWAYS"/> but to no avail).
    Best bet, if it is indeed possible to translate the "???Page???" in an af:table in a portal application, would be to add something to ResourceLibraryBundle but I don't know what trans-unit id.
    There's a handful of this exact question (e.g. https://forums.oracle.com/message/10620083) but no answers, either the solution is very obvious or there is no solution other than hard-coding the skin (which would not be that much of a problem).
    Any ideas?

    Thank you again!
    I'm using JDeveloper 10g.
    First, I've created a custom resource bundle (com.ieci.mugeju.view.resource.MugejuResourceBundle) and overrided the default resource string values.
    Second, I've created the file adf-faces-skins.xml like this:
    <?xml version="1.0" encoding="windows-1252" ?>
    <skins xmlns="http://xmlns.oracle.com/adf/view/faces/skin">
    <skin>
    <id>MugejuSkin</id>
    <family>MugejuSkin</family>
    <render-kit-id>oracle.adf.desktop</render-kit-id>
    <bundle-name>
    com.ieci.mugeju.view.resource.MugejuResourceBundle
    </bundle-name>
    </skin>
    </skins>
    Third, I set the skin-family property of the file adf-faces-config.xml to 'MugejuSkin'.
    If I follow all these steps, I achieve to change the text in ADF Faces components, as I wanted, but I lost the oracle styles (skin-family = oracle) that I had before following these steps.
    I must be doing someting wrong. I would like both, to mantain the oracle styles and to change the text in ADF Faces components.
    Thank you very much.

  • Resource Bundle var names

    After I do the necessary steps in the project properties to set up the resource bundle, when I start using the resource bundle in my JSF, JDeveloper adds the following line into the JSF.
    <c:set var="viewcontrollerBundle1"
    value="#{adfBundle['resb.view.untitled1Bundle']}"/>
    If I have multiple bundles, Jdeveloper adds one entry per resource bundles that I use within my JSF. But the name that is used is different in different JSF pages for the same bundle. I need to manually edit them. Is there a better way of handling this? Can we define the var that it has to be used for each bundle some where?
    Thanks,
    Manoj

    Hi Manoj,
    You dont need to declare it in the pages but configure them in faces-config.xml like below:
    <resource-bundle>
          <base-name>YourBaseResourceBundle</base-name>
          <var>res</var>
        </resource-bundle>Regards,
    Pino

  • Resource Bundle being overwritten

    Hello,
    We are upgrading from jhs 9.03 to jhs 9.0.4.4. A new feature is resource bundles and that is were we are having problems with.
    We have two jhs subapplications and I want to use the same resource bundle class for both applications. The problem is that every time I start JAG the class is being overwritten and not append to the existing class.
    There is a other project that also uses jhs and has two subapplications. They don't have that problem. There the class is not overwritten every time.
    I first tried using JDeveloper 9.0.3.1, but also tried it with JDeveloper 9.0.3.3. Both had this problem.
    Does anyone have a idea what this could be? When does JAG decide that the file should be overwritten?
    Thanx,
    Dennis

    Dennis,
    The JAG loads the existing COMPILED resource bundle. So, make sure you compile your resource bundle before you run the JAG, and make sure it is on the classpath of your project.
    Lastly, make sure you set "Override NLS Resource Bundle Entries" to false in the Application Structure Editor.
    Steven Davelaar,
    JHeadstart Team.

  • What are Resource Bundle Best Practices techniques for Enterprise App?

    Regarding JDeveloper: 11.1.1.6.0, Studio Edition
    I was wondering if someone could provide advice on Best Practices for managing Resource Bundles for an international Enterprise Application.
    I have been reading textbooks and throughout the web, and I can find different options available. And I can find cautionary tales to get it right at the beginning of Development, but I cannot find Best Practices suggestions.
    For instance:
    - Should I use XLIFF Resource Bundle, Properties Bundle, or List Resource Bundle?
    - What are the benefits and disadvantages of storing the Key/Value pairs in the database?
    - It seems that storing in the db would make maintenance easier, because applications do not need to be redeployed, but would they be slower?
    - One textbook indicates that "One Bundle per Project" is preferred for ViewController Project, and "One Bundle Per File" is preferred for Model Project. However, I cannot help but think if the whole Enterprise used just one Resource Bundle, it would save typing cust_id/Customer Number in 10 different Bundles.
    - One text indicates how to maintain translated versions of Access Keys, if the Bundle is a Properties Bundle, but provides no assistance for other Resource Bundles.
    Advice regarding Best Practices would be quite helpful.
    Sincerely,
    Arie

    Anyone?

  • Skin's resource bundle

    Hello,
    I'm using the Oracle skin in an ADF application. I would need a new "skin's resource bundle" for an unsupported locale. How could I do it? Which is the name of the Oracle Resource bundle class (or properties file)?
    Thanks in advance!

    Thank you again!
    I'm using JDeveloper 10g.
    First, I've created a custom resource bundle (com.ieci.mugeju.view.resource.MugejuResourceBundle) and overrided the default resource string values.
    Second, I've created the file adf-faces-skins.xml like this:
    <?xml version="1.0" encoding="windows-1252" ?>
    <skins xmlns="http://xmlns.oracle.com/adf/view/faces/skin">
    <skin>
    <id>MugejuSkin</id>
    <family>MugejuSkin</family>
    <render-kit-id>oracle.adf.desktop</render-kit-id>
    <bundle-name>
    com.ieci.mugeju.view.resource.MugejuResourceBundle
    </bundle-name>
    </skin>
    </skins>
    Third, I set the skin-family property of the file adf-faces-config.xml to 'MugejuSkin'.
    If I follow all these steps, I achieve to change the text in ADF Faces components, as I wanted, but I lost the oracle styles (skin-family = oracle) that I had before following these steps.
    I must be doing someting wrong. I would like both, to mantain the oracle styles and to change the text in ADF Faces components.
    Thank you very much.

Maybe you are looking for