質問編集履歴
2
■データ取得箇所 の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -37,11 +37,7 @@
|
|
37
37
|
}
|
38
38
|
|
39
39
|
■データ取得箇所
|
40
|
-
private void Menu_Load(object sender, EventArgs e)
|
41
|
-
{
|
42
|
-
|
43
|
-
|
44
|
-
|
40
|
+
private void frmMenu_Load(object sender, EventArgs e)
|
45
41
|
{
|
46
42
|
try
|
47
43
|
{
|
1
■データ取得箇所の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -41,27 +41,29 @@
|
|
41
41
|
{
|
42
42
|
|
43
43
|
|
44
|
+
private void frmMenu_Load(object sender, EventArgs e)
|
45
|
+
{
|
44
46
|
try
|
45
47
|
{
|
46
48
|
// テンプレート
|
47
|
-
Data
|
49
|
+
clsDataBaseAccessManager dam = new clsDataBaseAccessManager();
|
48
|
-
DataTable dt
|
50
|
+
DataTable dtClinic = new DataTable();
|
49
51
|
using (SQLiteCommand cmd = dam.CreateCommand())
|
50
52
|
{
|
51
53
|
string sql = "select * from MST_病院 where 病院コード = @code";
|
52
54
|
cmd.CommandText = sql;
|
53
|
-
cmd.Parameters.Add(new SQLiteParameter("@code", "
|
55
|
+
cmd.Parameters.Add(new SQLiteParameter("@code", "1"));
|
54
|
-
dt
|
56
|
+
dtClinic = dam.ExecuteQuery(cmd);
|
55
57
|
}
|
58
|
+
|
56
|
-
|
59
|
+
dam.CloseConnection();
|
57
|
-
la
|
60
|
+
lblClinicNameMenu.Text = dtClinic.Rows[0]["病院名"].ToString();
|
58
|
-
|
61
|
+
|
59
|
-
|
60
62
|
}
|
61
63
|
|
62
64
|
catch (Exception ex)
|
63
65
|
{
|
64
|
-
MessageBox.Show(ex.Message);
|
66
|
+
MessageBox.Show(ex.Message);
|
65
67
|
}
|
66
68
|
}
|
67
69
|
|