ADF mobile- cant able to open Anroid SDK Manager

when i tried to open SDK anroid manager, but i can’t able to open.What was the cause …
path of jre is missing in anroid.bat file

Soution is –

Open up tools/android.bat in your favorite text editor
Search for this piece of code:

set java_exe=
Replace it with this:

set java_exe=”D:\Program Files\Java\jdk1.7.0_07\bin\java.exe”
where the path is the your Java exe.

Run android.bat and you will be able to open anroid sdk manager…

ADF mobile error- failed to locate the Google Cloud Messaging for Android Library file named “gcm.jar”.

Let start ADF mobile now….

Error – Following error is hit when trying to deploy an ADF Mobile application.

Failed to locate the Google Cloud Messaging for Android Library file named “gcm.jar”. (oracle.adfmf.framework.dt.deploy.android.deployers.ValidatePreferencesDeployer)

CAUSE-
1. You are not using the correct version of ADF Mobile extension that is certified with your JDeveloper version.
2. You don’t have enough android SDK jars installed on your system

There are some jar missing in my anroid sdk manager.install it.

That’s it. Install some missing jar… enjoy coding in ADF mobile…

Set value in attribute in binding in Oracle ADF

Requirement – how to set value of attribute value in binding…

Solutions – you can use this expression –

JsfUtils.setExpressionValue("#{ManagedBean.empName}", "Vinay"); 

You have to add this method in JsfUtils class.

Note to call the getters and setters via your EL expression, you don’t include the get/set prefix.

 public static void setExpressionValue(String expression, Object newValue) {
    FacesContext facesContext = getFacesContext();
    Application app = facesContext.getApplication();
    ExpressionFactory elFactory = app.getExpressionFactory();
    ELContext elContext = facesContext.getELContext();
    ValueExpression valueExp = elFactory.createValueExpression(elContext, expression, Object.class);

    //Check that the input newValue can be cast to the property type
    //expected by the managed bean.
    //If the managed Bean expects a primitive we rely on Auto-Unboxing
    //I could do a more comprehensive check and conversion from the object
    //to the equivilent primitive but life is too short
    Class bindClass = valueExp.getType(elContext);
    if (bindClass.isPrimitive() || bindClass.isInstance(newValue)) {
      valueExp.setValue(elContext, newValue);
    }
  }

Happy coding in Techartifact with Vinay…