小区物业管理系统-物业管理员页面
Posted CaoPengCheng&
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了小区物业管理系统-物业管理员页面相关的知识,希望对你有一定的参考价值。
小区物业管理系统-物业管理员页面
主页面
添加业主
Public Class PropertyManager_Pro_insert
'bug:插入:若删除一个,用count就会插入相同的,导致插入错误
Dim proprietor As New Proprietor
Public Sub New(s As String)
InitializeComponent()
End Sub
Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click
'MsgBox(Len(TextBox1.Text))
If (TextBox1.Text = "" Or Len(TextBox1.Text) > 5) Then
MsgBox("请输入姓名或姓名格式错误!")
Else
If (RadioButton1.Checked = False And RadioButton2.Checked = False) Then
MsgBox("请选择性别!")
Else
If (TextBox3.Text = "" Or Int(TextBox3.Text) < 0 Or Int(TextBox3.Text) > 150) Then
MsgBox("请输入正确年龄!")
Else
If (TextBox4.Text = "" Or Len(TextBox4.Text) > 5) Then
MsgBox("请输入籍贯或籍贯格式错误!")
Else
If (proprietor.fGet = False) Then
MsgBox("请选择房屋和车库")
Else
proprietor.pnameSet(TextBox1.Text)
If (RadioButton1.Checked = True) Then
proprietor.psexSet("男")
End If
If (RadioButton2.Checked = True) Then
proprietor.psexSet("女")
End If
proprietor.pageSet(Int(TextBox3.Text))
proprietor.pnativeSet(TextBox4.Text)
Dim i As Integer = y()
proprietor.pnoSet("Y00" + i)
' MsgBox(proprietor.pnoGet)
NumberUpdata("y", i + 1)
proprietorAllInsert(proprietor)
Dim user As New User
user.usernameSet(proprietor.pnoGet)
user.tableSet("User_Proprietor")
User_Insert(user)
cost_Insert(proprietor.pnoGet, proprietor.p_bnoGet)
Label9.Text = "成功:请记住业主号"
Label12.Text = proprietor.pnoGet
Label16.Text = "系统初始密码:123"
End If
End If
End If
End If
End If
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim pbg As New PropertyManager_Pro_insert_B_G(proprietor)
pbg.ShowDialog()
'MsgBox(proprietor.p_gnoGet)
'MsgBox(proprietor.p_bnoGet)
If (proprietor.fGet) Then
Button1.Visible = False
Button2.Visible = False
Label2.Visible = True
Label6.Visible = True
Label6.Text = BuildingAddresss(proprietor.p_bnoGet)
Label2.Text = garageAll(proprietor.p_gnoGet)
End If
End Sub
Private Sub PropertyManager_Pro_insert_Load(sender As Object, e As EventArgs) Handles MyBase.Load
'设置同步时间显示
proprietor.fSet(False)
Label2.Visible = False
Label6.Visible = False
Button1.Visible = True
Button2.Visible = True
Label10.Text = Format(Now, "yyyy-mm-dd")
Label11.Text = Format(Now, "hh:mm:ss")
Label9.Text = ""
Label12.Text = ""
Label16.Text = ""
End Sub
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
Me.Close()
End Sub
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
Dim pbg As New PropertyManager_Pro_insert_B_G(proprietor)
pbg.ShowDialog()
'MsgBox(proprietor.p_gnoGet)
'MsgBox(proprietor.p_bnoGet)
If (proprietor.fGet) Then
Button1.Visible = False
Button2.Visible = False
Label2.Visible = True
Label6.Visible = True
Label6.Text = BuildingAddresss(proprietor.p_bnoGet)
Label2.Text = garageAll(proprietor.p_gnoGet)
End If
End Sub
End Class
业主查询
Public Class PropertyManager_Pro_add
Dim prop As Proprietor
Public Sub New(u As String)
InitializeComponent()
End Sub
Private Sub Button8_Click(sender As Object, e As EventArgs) Handles Button8.Click
If (proprietorSelectCount(TextBox1.Text) > 0) Then
Button8.Visible = False
Button9.Visible = False
Label18.Visible = False
TextBox1.Visible = False
Label1.Visible = True
Label2.Visible = True
Label3.Visible = True
Label5.Visible = True
Label6.Visible = True
Label7.Visible = True
Label8.Visible = True
Label9.Visible = True
Label10.Visible = True
Label11.Visible = True
Label12.Visible = True
Label16.Visible = True
Label17.Visible = True
Button2.Visible = True
Button3.Visible = True
Button4.Visible = True
Button6.Visible = True
prop = proprietorForPnoName(TextBox1.Text)
Label10.Text = prop.pnoGet()
Label17.Text = prop.pnameGet()
Label16.Text = prop.psexGet()
Label12.Text = prop.pageGet()
Label11.Text = prop.pnativeGet()
Label6.Text = garageAll(prop.p_gnoGet())
Label9.Text = BuildingAddresss(prop.p_bnoGet)
Else
MsgBox("业主不存在!!!")
End If
End Sub
Private Sub PropertyManager_Pro_add_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Label19.Text = Format(Now, "yyyy-mm-dd")
Label4.Text = Format(Now, "hh:mm:ss")
Label1.Visible = False
Label2.Visible = False
Label3.Visible = False
Label5.Visible = False
Label6.Visible = False
Label7.Visible = False
Label8.Visible = False
Label9.Visible = False
Label10.Visible = False
Label11.Visible = False
Label12.Visible = False
Label16.Visible = False
Label17.Visible = False
Button2.Visible = False
Button3.Visible = False
Button4.Visible = False
Button6.Visible = False
End Sub
Private Sub Button9_Click(sender As Object, e As EventArgs) Handles Button9.Click
Me.Close()
End Sub
Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
Dim user As User = User_Select(prop.pnoGet, "User_Proprietor")
user.tableSet("User_Proprietor")
Dim uer As New Proprietor_UserUpdata(user)
uer.ShowDialog()
End Sub
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
Me.Close()
End Sub
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
'删除
MsgBox(prop.pnoGet)
User_Delete(prop.pnoGet)
cost_Delete(prop.pnoGet)
proprietor_Delete(prop.pnoGet)
MsgBox("删除成功")
Me.Close()
End Sub
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
Dim uer As New PropertyManager_Pro_updata(prop)
uer.ShowDialog()
prop = proprietorAll(prop.pnoGet)
Label10.Text = prop.pnoGet()
Label17.Text = prop.pnameGet()
Label16.Text = prop.psexGet()
Label12.Text = prop.pageGet()
Label11.Text = prop.pnativeGet()
Label6.Text = garageAll(prop.p_gnoGet())
Label9.Text = BuildingAddresss(prop.p_bnoGet)
End Sub
End Class
修改业主信息
Public Class PropertyManager_Pro_updata
Dim proprietor As Proprietor
Dim jbno, jgno As String
Public Sub New(p As Proprietor)
InitializeComponent()
proprietor = p
End Sub
Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click
'MsgBox(Len(TextBox1.Text))
If (TextBox1.Text = "" Or Len(TextBox1.Text) > 5) Then
MsgBox("请输入姓名或姓名格式错误!")
Else
If (RadioButton1.Checked = False And RadioButton2.Checked = False) Then
MsgBox("请选择性别!")
Else
If (TextBox3.Text = "" Or Int(TextBox3.Text) < 0 Or Int(TextBox3.Text) > 150) Then
MsgBox("请输入正确年龄!")
Else
If (TextBox4.Text = "" Or Len(TextBox4.Text) > 5) Then
MsgBox("请输入籍贯或籍贯格式错误!")
Else
proprietor.pnameSet(TextBox1.Text)
If (RadioButton1.Checked = True) Then
proprietor.psexSet("男")
End If
If (RadioButton2.Checked = True) Then
proprietor.psexSet("女")
End If
proprietor.pageSet(Int(TextBox3.Text))
proprietor.pnativeSet(TextBox4.Text)
' MsgBox(proprietor.pnoGet)
proprietorUP(proprietor)
Me.Close()
End If
End If
End If
End If
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim pbg As New PropertyManager_Pro_insert_B_G(proprietor)
pbg.ShowDialog()
'MsgBox(proprietor.p_gnoGet)
'MsgBox(proprietor.p_bnoGet)
If (proprietor.fGet) Then
Button1.Visible = False
Label6.Text = BuildingAddresss(proprietor.p_bnoGet)
Label2.Text = garageAll(proprietor.p_gnoGet)
End If
End Sub
Private Sub PropertyManager_Pro_updata_Load(sender As Object, e As EventArgs) Handles MyBase.Load
'设置同步时间显示
Proprietor.fSet(False)
Label10.Text = Format(Now, "yyyy-mm-dd")
Label11.Text = Format(Now, "hh:mm:ss")
'proprietor = proprietorAll("Y002")
TextBox1.Text = Trim(proprietor.pnameGet())
If (proprietor.psexGet() = "男") Then
RadioButton1.Checked = True
End If
If (proprietor.psexGet() = "女") Then
RadioButton2.Checked = True
End If
'MsgBox(proprietor.p_bnoGet)
TextBox3.Text = proprietor.pageGet()
TextBox4.Text = Trim(proprietor.pnativeGet())
Label6.Text = BuildingAddresss(proprietor.p_bnoGet)
Label2.Text = garageAll(proprietor.p_gnoGet)
jbno = proprietor.p_bnoGet
jgno = proprietor.p_gnoGet
End Sub
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
Me.Close()
End Sub
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
'设置同步时间显示
proprietor.fSet(False)
'proprietor = proprietorAll("Y002")
TextBox1.Text = Trim(proprietor.pnameGet())
If (proprietor.psexGet() = "男") Then
RadioButton1.Checked = True
End If
If (proprietor.psexGet() = "女") Then
RadioButton2.Checked = True
End If
'MsgBox(proprietor.p_bnoGet)
TextBox3.Text = proprietor.pageGet()
TextBox4.Text = Trim(proprietor.pnativeGet())
Label6.Text = BuildingAddresss(jbno)
Label2.Text = garageAll(jgno)
Button1.Visible = True
End Sub
End Class
房屋车库选择
Public Class PropertyManager_Pro_insert_B_G
Dim pro As Proprietor
Public Sub New(p As Proprietor)
InitializeComponent()
pro = p
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
ListBox1.Items.Clear()
ListBox2.Items.Clear()
ListBox3.Items.Clear()
ListBox4.Items.Clear()
ListBox5.Items.Clear()
Label1.Text = ""
Label2.Text = ""
ListBox1.Visible = True
ListBox2.Visible = True
ListBox4.Visible = True
ListBox3.Visible = True
Label5.Visible = True
Label6.Visible = True
Label7.Visible = True
Label8.Visible = True
Button2.Visible = False
ListBox5.Visible = False
Button4.Visible = False
Dim s() As String = BuildingForBarea()
For i = 1 To Int(s(0))
ListBox1.Items.Add(s(i))
Next
End Sub
Private Sub PropertyManager_Pro_insert_B_G_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Label1.Text = ""
Label2.Text = ""
Label10.Text = Format(Now, "yyyy-mm-dd")
Label11.Text = Format(Now, "hh:mm:ss")
Button2.Visible = False
ListBox5.Visible = False
Button4.Visible = False
Dim s() As String = BuildingForBarea()
For i = 1 To Int(s(0))
ListBox1.Items.Add(s(i))
Next
End Sub
Private Sub ListBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListBox1.SelectedIndexChanged
Label1.Text = ListBox1.Text + "区 "
ListBox2.Items.Clear()
Dim s() As String = BuildingForBlouno(ListBox1.Text)
For i = 1 To Int(s(0))
ListBox2.Items.Add(s(i))
Next
End Sub
Private Sub ListBox2_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListBox2.SelectedIndexChanged
Label1.Text = Label1.Text + ListBox2.Text + "号楼 "
ListBox3.Items.Clear()
Dim s() As String = BuildingForBapartment(ListBox1.Text, ListBox2.Text)
For i = 1 To Int(s(0))
ListBox3.Items.Add(s(i))
Next
End Sub
Private Sub ListBox3_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListBox3.SelectedIndexChanged
Label1.Text = Label1.Text + ListBox3.Text + "单元 "
ListBox4.Items.Clear()
Dim s() As String = BuildingForBRoomNo(ListBox1.Text, ListBox2.Text, ListBox3.Text)
For i = 1 To Int(s(0))
ListBox4.Items.Add(s(i))
Next
End Sub
Private Sub ListBox4_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListBox4.SelectedIndexChanged
Label1.Text = Label1.Text + ListBox4.小区物业管理系统-业主页面编写