public override object CreateInsertCommandScript(PropertyGrid SelectedPgrid, string ProjectName, string TransactionName, int ExtensionStateNumber) { StateE State = new StateE(); State = (StateE)SelectedPgrid.SelectedObject; List <string> SqlStringList = new List <string>(); string sql = SqlStr; sql = string.Format(sql, Guid, Status, DateTime.Now.ToString("yyyyMMddHHmmss"), State.StateNumber, State.StateDescription, State.StateType, ProjectName, TransactionName, State.ScreenNumber, State.TimeoutNextState, State.CancelNextState, State.FDK_A_NextState, State.FDK_B_NextState, State.FDK_C_NextState, State.FDK_D_NextState, State.BufferLocation, State.ConfigId, State.BrandId, State.ConfigVersion); SqlStringList.Add(sql); return(SqlStringList); }
public override Object FillPropertyGridFromState(Object ClassInstance, PropertyGrid SelectedPgrid) { StateE Selectedstate = new StateE(); StateE Dynamicstate = new StateE(); Selectedstate = (StateE)SelectedPgrid.SelectedObject; Dynamicstate = (StateE)ClassInstance; Dynamicstate.BrandId = Selectedstate.BrandId; Dynamicstate.ConfigId = Selectedstate.ConfigId; Dynamicstate._Description = Selectedstate.StateDescription; Dynamicstate._bufferLocation = Selectedstate.BufferLocation; //Dynamicstate._cancelnextState = Selectedstate._cancelnextState; //Dynamicstate._fdkANextState = Selectedstate._fdkANextState; //Dynamicstate._fdkBNextState = Selectedstate._fdkBNextState; //Dynamicstate._fdkCNextState = Selectedstate._fdkCNextState; //Dynamicstate._fdkDNextState = Selectedstate._fdkDNextState; Dynamicstate._screen = Selectedstate.ScreenNumber; //Dynamicstate._timeoutnextState = Selectedstate._timeoutnextState; return(Dynamicstate); }
public override Object StateChanged(string SelectedProperty, string newValue, Object ClassInstance, PropertyGrid SelectedPgrid) { //FillStateFromPropertyGrid(ClassInstance, SelectedPgrid); StateE Selectedstate = new StateE(); StateE Dynamicstate = new StateE(); Selectedstate = (StateE)SelectedPgrid.SelectedObject; Dynamicstate = (StateE)ClassInstance; Dynamicstate._Description = Selectedstate.StateDescription; Dynamicstate.BrandId = Selectedstate.BrandId; Dynamicstate.ConfigId = Selectedstate.ConfigId; Dynamicstate._bufferLocation = Selectedstate.BufferLocation; Dynamicstate._cancelNextState = Selectedstate.CancelNextState; Dynamicstate._fdkANextState = Selectedstate.FDK_A_NextState; Dynamicstate._fdkBNextState = Selectedstate.FDK_B_NextState; Dynamicstate._fdkCNextState = Selectedstate.FDK_C_NextState; Dynamicstate._fdkDNextState = Selectedstate.FDK_D_NextState; Dynamicstate._screen = Selectedstate.ScreenNumber; Dynamicstate._timeoutNextState = Selectedstate.TimeoutNextState; return(Dynamicstate); }
public override object FillStatesFromDB(object[] processRow, ArrayList StateList) { StateE state = new StateE(); ModelCanvasStateObject TransStateObj = new ModelCanvasStateObject(); List <ModelParentStateObject> ParentobjList = new List <ModelParentStateObject>(); List <ModelChildStateObject> ChildobjList = new List <ModelChildStateObject>(); state.Status = processRow[1].ToString(); state.StateNumber = processRow[3].ToString(); state.StateDescription = processRow[4].ToString(); state.StateType = processRow[5].ToString(); state._screen = processRow[8].ToString(); state._timeoutNextState = processRow[9].ToString(); state._cancelNextState = processRow[10].ToString(); state._fdkANextState = processRow[11].ToString(); state._fdkBNextState = processRow[12].ToString(); state._fdkCNextState = processRow[13].ToString(); state._fdkDNextState = processRow[14].ToString(); state._bufferLocation = processRow[15].ToString(); state.ConfigId = processRow[16].ToString(); state.BrandId = processRow[17].ToString(); state.ConfigVersion = processRow[18].ToString(); //NextState Kontrolu #region nextState arrange-parent and pointer if (state.TimeoutNextState != "255") { ChildobjList.Add(GetChildState("TimeoutNextState", state.TimeoutNextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } if (state.CancelNextState != "255") { ChildobjList.Add(GetChildState("CancelNextState", state.CancelNextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } if (state.FDK_A_NextState != "255") { ChildobjList.Add(GetChildState("FDK_A_NextState", state.FDK_A_NextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } if (state.FDK_B_NextState != "255") { ChildobjList.Add(GetChildState("FDK_B_NextState", state.FDK_B_NextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } if (state.FDK_C_NextState != "255") { ChildobjList.Add(GetChildState("FDK_C_NextState", state.FDK_C_NextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } if (state.FDK_D_NextState != "255") { ChildobjList.Add(GetChildState("FDK_D_NextState", state.FDK_D_NextState, StateList, processRow[7].ToString(), state.StateType, state.StateNumber)); } #endregion TransStateObj.BrandId = state.BrandId; TransStateObj.ConfigId = state.ConfigId; TransStateObj.Id = state.StateNumber; TransStateObj.StateDescription = state.StateDescription; TransStateObj.Type = state.StateType; TransStateObj.TransactionName = processRow[7].ToString(); TransStateObj.PropertyGrid.SelectedObject = state; TransStateObj.ParentStateList = ParentobjList; TransStateObj.ChildStateList = ChildobjList; designerCanvas.TransactionList.Add(TransStateObj); return(StateList); }