This discussion is archived
1 2 Previous Next 15 Replies Latest reply: Jan 28, 2013 7:24 PM by thishum Go to original post RSS
  • 15. Re: how to work multi task applications as a one application
    thishum Explorer
    Currently Being Moderated
    hi,
    another issue for me..
    I add my remote applications into local application. But in here my Save button is in local page. problem is in DataControl pannel all remote application datacontrols and local app Datacontrol are there.
    BUT how should I go to add remote application page data and local app page data save??
    is it in this way///
    BindingContext bc =BindingContext.getCurrent();
    DataControlFrame dcf= bc.findDataControlFrame(bc.getCurrentDataControlFrame());
    Collection<DCDataControl> dcCol =dcf.datacontrols();
    for(DCDataControl dCDataControl : dcCol) {
    if(dCDataControl.isTransactionDirty()){
    try{
    dCDataControl.commitTransaction();
    }
    catch(Exception e) {
    FacesContext facesContext = FacesContext.getCurrentInstance();
    facesContext.addMessage(null, new FacesMessage(FacesMessage.SEVERITY_ERROR, e.getMessage(), null));
    e.printStackTrace();
    }
    }
    DataControlFrame dcframe = bc.findDataControlFrame("TestRemoteAppDataControl"); // Remote Application DataControl
    DataControl dc = dcframe.findDataControl("TestRemoteAppDataControl");
    dcframe.commit();
    dcframe.beginTransaction(null);

    (Remote page data is not saved.. but local is ok..)
    how to commit remote app data?? anyone who know this??
    hoping help.
    thks.
1 2 Previous Next

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points