Ejemplo n.º 1
0
        private void LoadDataRadnomjesto(int maxRows)
        {
            int num = 0;

            if (this.RcdFound26 != 0)
            {
                this.ScanLoadRadnomjesto();
                while ((this.RcdFound26 != 0) && (num != maxRows))
                {
                    num++;
                    this.LoadRowRadnomjesto();
                    this.CreateNewRowRadnomjesto();
                    this.ScanNextRadnomjesto();
                }
            }
            if (num > 0)
            {
                this.RcdFound26 = 1;
            }
            this.ScanEndRadnomjesto();
            if (this.RADNOMJESTOSet.RADNOMJESTO.Count > 0)
            {
                this.rowRADNOMJESTO = this.RADNOMJESTOSet.RADNOMJESTO[this.RADNOMJESTOSet.RADNOMJESTO.Count - 1];
            }
        }
Ejemplo n.º 2
0
 public RADNOMJESTODataSet.RADNOMJESTORow AddRADNOMJESTORow(int iDRADNOMJESTO, string nAZIVRADNOMJESTO)
 {
     RADNOMJESTODataSet.RADNOMJESTORow row = (RADNOMJESTODataSet.RADNOMJESTORow) this.NewRow();
     row["IDRADNOMJESTO"]    = iDRADNOMJESTO;
     row["NAZIVRADNOMJESTO"] = nAZIVRADNOMJESTO;
     this.Rows.Add(row);
     return(row);
 }
Ejemplo n.º 3
0
        private void LoadByIDRADNOMJESTO(int startRow, int maxRows)
        {
            bool enforceConstraints = this.RADNOMJESTOSet.EnforceConstraints;

            this.RADNOMJESTOSet.RADNOMJESTO.BeginLoadData();
            this.ScanByIDRADNOMJESTO(startRow, maxRows);
            this.RADNOMJESTOSet.RADNOMJESTO.EndLoadData();
            this.RADNOMJESTOSet.EnforceConstraints = enforceConstraints;
            if (this.RADNOMJESTOSet.RADNOMJESTO.Count > 0)
            {
                this.rowRADNOMJESTO = this.RADNOMJESTOSet.RADNOMJESTO[this.RADNOMJESTOSet.RADNOMJESTO.Count - 1];
            }
        }
Ejemplo n.º 4
0
 private void ReadRowRadnomjesto()
 {
     this.Gx_mode = Mode.FromRowState(this.rowRADNOMJESTO.RowState);
     if (this.rowRADNOMJESTO.RowState != DataRowState.Added)
     {
         this.m__NAZIVRADNOMJESTOOriginal = RuntimeHelpers.GetObjectValue(this.rowRADNOMJESTO["NAZIVRADNOMJESTO", DataRowVersion.Original]);
     }
     else
     {
         this.m__NAZIVRADNOMJESTOOriginal = RuntimeHelpers.GetObjectValue(this.rowRADNOMJESTO["NAZIVRADNOMJESTO"]);
     }
     this._Gxremove = this.rowRADNOMJESTO.RowState == DataRowState.Deleted;
     if (this._Gxremove)
     {
         this.rowRADNOMJESTO = (RADNOMJESTODataSet.RADNOMJESTORow)DataSetUtil.CloneOriginalDataRow(this.rowRADNOMJESTO);
     }
 }
Ejemplo n.º 5
0
 public virtual bool FillByIDRADNOMJESTO(RADNOMJESTODataSet dataSet, int iDRADNOMJESTO)
 {
     this.InitializeMembers();
     this.connDefault    = this.dsDefault.GetReadWriteConnection(this.daCurrentTransaction);
     this.RADNOMJESTOSet = dataSet;
     this.rowRADNOMJESTO = this.RADNOMJESTOSet.RADNOMJESTO.NewRADNOMJESTORow();
     this.rowRADNOMJESTO.IDRADNOMJESTO = iDRADNOMJESTO;
     try
     {
         this.LoadByIDRADNOMJESTO(0, -1);
         dataSet.AcceptChanges();
     }
     finally
     {
         this.Cleanup();
     }
     if (this.RcdFound26 == 0)
     {
         return(false);
     }
     return(true);
 }
Ejemplo n.º 6
0
 public RADNOMJESTORowChangeEvent(RADNOMJESTODataSet.RADNOMJESTORow row, DataRowAction action)
 {
     this.eventRow    = row;
     this.eventAction = action;
 }
Ejemplo n.º 7
0
 public void RemoveRADNOMJESTORow(RADNOMJESTODataSet.RADNOMJESTORow row)
 {
     this.Rows.Remove(row);
 }
Ejemplo n.º 8
0
 public void AddRADNOMJESTORow(RADNOMJESTODataSet.RADNOMJESTORow row)
 {
     this.Rows.Add(row);
 }
Ejemplo n.º 9
0
 public RADNOMJESTOEventArgs(RADNOMJESTODataSet.RADNOMJESTORow row, System.Data.StatementType statementType)
 {
     this.m_dataRow       = row;
     this.m_statementType = statementType;
 }
Ejemplo n.º 10
0
        public virtual int Update(DataSet dataSet)
        {
            this.InitializeMembers();
            this.RADNOMJESTOSet = (RADNOMJESTODataSet)dataSet;
            this.connDefault    = this.dsDefault.GetReadWriteConnection(this.daCurrentTransaction);
            if (this.RADNOMJESTOSet == null)
            {
                throw new ArgumentException(this.resourceManager.GetString("nulldset"));
            }
            try
            {
                IEnumerator enumerator = null;
                this.connDefault.BeginTransaction();
                try
                {
                    enumerator = this.RADNOMJESTOSet.RADNOMJESTO.GetEnumerator();
                    while (enumerator.MoveNext())
                    {
                        RADNOMJESTODataSet.RADNOMJESTORow current = (RADNOMJESTODataSet.RADNOMJESTORow)enumerator.Current;
                        this.rowRADNOMJESTO = current;
                        if (Helpers.IsRowChanged(this.rowRADNOMJESTO))
                        {
                            this.ReadRowRadnomjesto();
                            if (this.rowRADNOMJESTO.RowState == DataRowState.Added)
                            {
                                this.InsertRadnomjesto();
                            }
                            else
                            {
                                if (this._Gxremove)
                                {
                                    this.Delete();
                                    continue;
                                }
                                this.UpdateRadnomjesto();
                            }
                        }
                    }
                }
                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);
        }
Ejemplo n.º 11
0
 private void CreateNewRowRadnomjesto()
 {
     this.rowRADNOMJESTO = this.RADNOMJESTOSet.RADNOMJESTO.NewRADNOMJESTORow();
 }