- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
- 38
- 39
- 40
- 41
- 42
- 43
- 44
- 45
- 46
- 47
- 48
- 49
- 50
- 51
- 52
- 53
- 54
- 55
- 56
- 57
- 58
- 59
- 60
- 61
- 62
- 63
- 64
OleDbCommand command = new OleDbCommand("select * from Прейскурант where ID = 1", bd);
OleDbDataReader dataReader1 = command.ExecuteReader();
string st;
dataReader1.Read();
int i = 0;
while (i < dataReader1.FieldCount)
{
st = dataReader1.GetValue(i).ToString();
switch (i)
{
case 0:
textBox1.Text = st;
break;
case 1:
textBox2.Text = st;
break;
case 2:
textBox3.Text = st;
break;
case 3:
textBox4.Text = st;
break;
case 4:
textBox5.Text = st;
break;
case 5:
textBox6.Text = st;
break;
case 6:
textBox7.Text = st;
break;
case 7:
textBox8.Text = st;
break;
case 8:
textBox9.Text = st;
break;
case 9:
textBox10.Text = st;
break;
case 10:
textBox11.Text = st;
break;
case 11:
textBox12.Text = st;
break;
case 12:
textBox13.Text = st;
break;
case 13:
textBox14.Text = st;
break;
case 14:
textBox15.Text = st;
break;
}
i++;
}
dataReader1.Close();
bd.Close();
betking1 21.07.2017 15:32 # −5
stasheLogan 05.09.2017 15:39 # −5
p.s. код не мой )
pyshpysh 24.08.2021 00:47 # 0