0 Replies Latest reply on Oct 19, 2009 4:33 PM by RedOctober57

    How do I refresh my textInput fields from the DB?

    RedOctober57 Level 1

      Here is how I load data into a form (it's a component, loaded and displayed as a popup):


                  protected function panel1_updateCompleteHandler(event:FlexEvent):void
                      rec_obj_guid = parentApplication.grdSBJs.selectedItem.OBJ_GUID;
                      getSBJResult.token = baa_data_svc.getSBJ(rec_obj_guid);


      Commit button:

                  protected function btnCommit_clickHandler(event:MouseEvent):void



      I have an Undo button that simply needs to discard the changes made by the user, and repopulate TextInputs from the DB.  What is the proper way to do this?


                  protected function btnUndo_clickHandler(event:MouseEvent):void
                     // WHAT GOES HERE ?




      ------------------- note ----------------------

      Doing another:

                      getSBJResult.token = baa_data_svc.getSBJ(rec_obj_guid);

      doesn't throw an error, but the data in the TextInputs doesn't get refreshed back to the unedited state.



      Also here are the variable declarations.  Are they OK?




                  private var rec_obj_guid: String;
                  private var data_chngd: Boolean = false;