Пример #1
0
        private void LoadDataUgovororadu(int maxRows)
        {
            int num = 0;

            if (this.RcdFound271 != 0)
            {
                this.ScanLoadUgovororadu();
                while ((this.RcdFound271 != 0) && (num != maxRows))
                {
                    num++;
                    this.LoadRowUgovororadu();
                    this.CreateNewRowUgovororadu();
                    this.ScanNextUgovororadu();
                }
            }
            if (num > 0)
            {
                this.RcdFound271 = 1;
            }
            this.ScanEndUgovororadu();
            if (this.UGOVORORADUSet.UGOVORORADU.Count > 0)
            {
                this.rowUGOVORORADU = this.UGOVORORADUSet.UGOVORORADU[this.UGOVORORADUSet.UGOVORORADU.Count - 1];
            }
        }
Пример #2
0
 public UGOVORORADUDataSet.UGOVORORADURow AddUGOVORORADURow(int iDUGOVORORADU, string nAZIVUGOVORORADU)
 {
     UGOVORORADUDataSet.UGOVORORADURow row = (UGOVORORADUDataSet.UGOVORORADURow) this.NewRow();
     row["IDUGOVORORADU"]    = iDUGOVORORADU;
     row["NAZIVUGOVORORADU"] = nAZIVUGOVORORADU;
     this.Rows.Add(row);
     return(row);
 }
Пример #3
0
        private void LoadByIDUGOVORORADU(int startRow, int maxRows)
        {
            bool enforceConstraints = this.UGOVORORADUSet.EnforceConstraints;

            this.UGOVORORADUSet.UGOVORORADU.BeginLoadData();
            this.ScanByIDUGOVORORADU(startRow, maxRows);
            this.UGOVORORADUSet.UGOVORORADU.EndLoadData();
            this.UGOVORORADUSet.EnforceConstraints = enforceConstraints;
            if (this.UGOVORORADUSet.UGOVORORADU.Count > 0)
            {
                this.rowUGOVORORADU = this.UGOVORORADUSet.UGOVORORADU[this.UGOVORORADUSet.UGOVORORADU.Count - 1];
            }
        }
Пример #4
0
 private void ReadRowUgovororadu()
 {
     this.Gx_mode = Mode.FromRowState(this.rowUGOVORORADU.RowState);
     if (this.rowUGOVORORADU.RowState != DataRowState.Added)
     {
         this.m__NAZIVUGOVORORADUOriginal = RuntimeHelpers.GetObjectValue(this.rowUGOVORORADU["NAZIVUGOVORORADU", DataRowVersion.Original]);
     }
     else
     {
         this.m__NAZIVUGOVORORADUOriginal = RuntimeHelpers.GetObjectValue(this.rowUGOVORORADU["NAZIVUGOVORORADU"]);
     }
     this._Gxremove = this.rowUGOVORORADU.RowState == DataRowState.Deleted;
     if (this._Gxremove)
     {
         this.rowUGOVORORADU = (UGOVORORADUDataSet.UGOVORORADURow)DataSetUtil.CloneOriginalDataRow(this.rowUGOVORORADU);
     }
 }
Пример #5
0
 public virtual bool FillByIDUGOVORORADU(UGOVORORADUDataSet dataSet, int iDUGOVORORADU)
 {
     this.InitializeMembers();
     this.connDefault    = this.dsDefault.GetReadWriteConnection(this.daCurrentTransaction);
     this.UGOVORORADUSet = dataSet;
     this.rowUGOVORORADU = this.UGOVORORADUSet.UGOVORORADU.NewUGOVORORADURow();
     this.rowUGOVORORADU.IDUGOVORORADU = iDUGOVORORADU;
     try
     {
         this.LoadByIDUGOVORORADU(0, -1);
         dataSet.AcceptChanges();
     }
     finally
     {
         this.Cleanup();
     }
     if (this.RcdFound271 == 0)
     {
         return(false);
     }
     return(true);
 }
Пример #6
0
 public UGOVORORADURowChangeEvent(UGOVORORADUDataSet.UGOVORORADURow row, DataRowAction action)
 {
     this.eventRow    = row;
     this.eventAction = action;
 }
Пример #7
0
 public void RemoveUGOVORORADURow(UGOVORORADUDataSet.UGOVORORADURow row)
 {
     this.Rows.Remove(row);
 }
Пример #8
0
 public void AddUGOVORORADURow(UGOVORORADUDataSet.UGOVORORADURow row)
 {
     this.Rows.Add(row);
 }
Пример #9
0
 public UGOVORORADUEventArgs(UGOVORORADUDataSet.UGOVORORADURow row, System.Data.StatementType statementType)
 {
     this.m_dataRow       = row;
     this.m_statementType = statementType;
 }
Пример #10
0
        public virtual int Update(DataSet dataSet)
        {
            this.InitializeMembers();
            this.UGOVORORADUSet = (UGOVORORADUDataSet)dataSet;
            this.connDefault    = this.dsDefault.GetReadWriteConnection(this.daCurrentTransaction);
            if (this.UGOVORORADUSet == null)
            {
                throw new ArgumentException(this.resourceManager.GetString("nulldset"));
            }
            try
            {
                IEnumerator enumerator = null;
                this.connDefault.BeginTransaction();
                try
                {
                    enumerator = this.UGOVORORADUSet.UGOVORORADU.GetEnumerator();
                    while (enumerator.MoveNext())
                    {
                        UGOVORORADUDataSet.UGOVORORADURow current = (UGOVORORADUDataSet.UGOVORORADURow)enumerator.Current;
                        this.rowUGOVORORADU = current;
                        if (Helpers.IsRowChanged(this.rowUGOVORORADU))
                        {
                            this.ReadRowUgovororadu();
                            if (this.rowUGOVORORADU.RowState == DataRowState.Added)
                            {
                                this.InsertUgovororadu();
                            }
                            else
                            {
                                if (this._Gxremove)
                                {
                                    this.Delete();
                                    continue;
                                }
                                this.UpdateUgovororadu();
                            }
                        }
                    }
                }
                finally
                {
                    if (enumerator is IDisposable)
                    {
                        (enumerator as IDisposable).Dispose();
                    }
                }
                dataSet.AcceptChanges();
                this.connDefault.Commit();
            }
            catch (System.Exception exception1)
            {
                throw exception1;

                //this.connDefault.Rollback();
            }
            finally
            {
                this.Cleanup();
            }
            return(0);
        }
Пример #11
0
 private void CreateNewRowUgovororadu()
 {
     this.rowUGOVORORADU = this.UGOVORORADUSet.UGOVORORADU.NewUGOVORORADURow();
 }