Пример #1
0
        private void ZeroCso_FormClosing(object sender, FormClosingEventArgs e)
        {
            WorkData ma;

            for (int a = 0; a < csoGrid.RowCount; a++)
            {
                ma = (WorkData)csoGrid[0, a].Value;
                kdao.GetLatLngProb(ma);
            }
        }
Пример #2
0
        private void ZeroLatLng_FormClosing(object sender, FormClosingEventArgs e)
        {
            WorkData ma;

            if (DialogResult == DialogResult.OK)
            {
                for (int a = 0; a < csoGrid.RowCount; a++)
                {
                    ma = (WorkData)csoGrid[0, a].Value;
                    dao.GetLatLngProb(ma);
                    dao.InsertLatLng(ma);
                }
            }
            else
            {
                for (int a = 0; a < csoGrid.RowCount; a++)
                {
                    ma     = (WorkData)csoGrid[0, a].Value;
                    ma.Lat = ma.Lng = 0;
                }
            }
        }
Пример #3
0
        private void csoGrid_CellValueChanged(object sender, DataGridViewCellEventArgs e)
        {
            WorkData wd = repo.Find((int)csoGrid[8, e.RowIndex].Value);

            switch (e.ColumnIndex)
            {
            case 4:
                //Utca
                dao.GetLatLngProb(wd);
                if (OnStreetChange != null)
                {
                    OnStreetChange(wd.Number);
                }
                break;

            case 7:
                if (OnProbChange != null)
                {
                    OnProbChange(wd.Number, wd.Problematic);
                }
                break;
            }
        }