毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 课程设计 >> 正文

医院挂号划价管理信息系统 第5页

更新时间:2008-6-25:  来源:毕业论文

医院挂号划价管理信息系统 第5页

 InitDataTalbe()

    End Sub

 

    Private Sub txbPY_KeyDown(ByVal sender As Object, _

    ByVal e As System.Windows.Forms.KeyEventArgs) _

    Handles txbPY.KeyDown

        If e.KeyCode = Keys.Enter Then

            Dim dlg As frmSelectHuaJiaMX = New frmSelectHuaJiaMX

            dlg.strPY = Me.txbPY.Text.Trim

            dlg.ShowDialog()

            Dim strId As String = dlg.GetInfo()

            Dim db As DataBase = New DataBase

            Dim dv As DataView = _

        db.RunSelectSQL("select * from v收费项目及药品 where 编号='" _

             + strId + "'")

            Me.txbMXId.Text = dv(0)("编号")

            Me.txbPY.Text = dv(0)("拼音码")

            Me.txbMName.Text = dv(0)("名称")

            Me.txbGuiGe.Text = dv(0)("规格")

            Me.txbUnit.Text = dv(0)("单位")

            Me.txbPrice.Text = dv(0)("单价")

            Me.txbNumber.Text = "1"

            db.Dispose()

        End If

    End Sub

 

    Private Sub btnDel_Click(ByVal sender As System.Object, _

    ByVal e As System.EventArgs) Handles btnDel.Click

        Try

            '获得DataGrid当前被选中的行号

            Dim iRow = dgdList.CurrentRowIndex

            '弹出对话框让用户确认要删除记录

            '如果用户确认要删除记录

            If MessageBox.Show("你确认要删除此条记录吗?", _

       "Confirm", MessageBoxButtons.YesNo) = DialogResult.Yes Then

                '从商品清单表删除当前被选中记录()

                dtDetail.Rows(iRow).Delete()

                ' SetTaxForDelOrUpgrade()

                If dtDetail.Rows.Count = 0 Then

                    iCurrentLine = -1

                End If

                ClearMX()

            Else

                Exit Sub

            End If

        Catch ex As Exception

            MessageBox.Show("删除数据出错")

        End Try

        CalTotalMoney()

    End Sub

 

    Private Sub dgdList_CurrentCellChanged(ByVal sender As Object, _

              iCurrentLine = dgdList.CurrentCell.RowNumber

        End If

        Dim iRow As Integer = dgdList.CurrentRowIndex

        txbMXId.Text = dtDetail.Rows(iRow)("编号")

        txbMName.Text = dtDetail.Rows(iRow)("名称")

        txbGuiGe.Text = dtDetail.Rows(iRow)("规格")

        txbUnit.Text = dtDetail.Rows(iRow)("单位")

        txbPrice.Text = dtDetail.Rows(iRow)("单价")

        txbNumber.Text = dtDetail.Rows(iRow)("数量")

        txbMMoney.Text = dtDetail.Rows(iRow)("金额")

        txbPY.Text = dtDetail.Rows(iRow)("拼音码")

    End Sub

 

    Private Sub btnSave_Click(ByVal sender As System.Object, _

    ByVal e As System.EventArgs) Handles btnSave.Click

        If dgdList.CurrentRowIndex = -1 Then

            Return

        dtDetail.Rows(iCurrentLine)("单价") = txbPrice.Text

        dtDetail.Rows(iCurrentLine)("数量") = txbNumber.Text

        dtDetail.Rows(iCurrentLine)("金额") = txbMMoney.Text

        dtDetail.Rows(iCurrentLine)("拼音码") = txbPY.Text

        ClearMX()

        CalTotalMoney()

    End Sub

 

    Private Sub btnCancel_Click(ByVal sender As System.Object, _

上一页  [1] [2] [3] [4] [5] [6] [7] 下一页

医院挂号划价管理信息系统 第5页下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©751com.cn 辣文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。