Greetings,
I am very green to VB.NET and programming in general so please take it easy on me! I am trying to create a webform for my place of business that will provide an On-Call website for all the applications we support, that can be easily updated when the on call person changes.
The database is an access Database and it has two tables.
MainPhoneList - contains all the possible people that can be on call
Fields
Name - Full Name
Pager- Pager Number
Cell- Cell Number
Office - Office Number
OnCall- contains the current on call people.
Fields
Name - Full Name
Pager - Pager Number
Cell - Cell Number
Office - Office Number
Comment - Comments
Application - Application person is on call for
I have made a contact class that I will use for this program and coded it below
Now for the part that I don't know how to accomplish. The web form will use a combo box for the name field and populate it with the names from the mainphonelist table. When someone selects a name from the list it autopopulates the pager, cell, office, and comments boxes on the webform and updates the oncall database as well.
All help is appreciated!!!!
I am very green to VB.NET and programming in general so please take it easy on me! I am trying to create a webform for my place of business that will provide an On-Call website for all the applications we support, that can be easily updated when the on call person changes.
The database is an access Database and it has two tables.
MainPhoneList - contains all the possible people that can be on call
Fields
Name - Full Name
Pager- Pager Number
Cell- Cell Number
Office - Office Number
OnCall- contains the current on call people.
Fields
Name - Full Name
Pager - Pager Number
Cell - Cell Number
Office - Office Number
Comment - Comments
Application - Application person is on call for
I have made a contact class that I will use for this program and coded it below
VB.NET:
Option Strict On
Public Class Contacts
Private mstrName As String
Private mstrCellNumber As String
Private mstrDeskNumber As String
Private mstrPagerNumber As String
Private mstrComment As String
Private Const g_strConnectionString As String = "Provider=Microsoft.Jet.OLEDB.4.0;" _
& _
"Data Source=C:\Documents and Settings\robby\Desktop\On-Call.mdb"
Public Sub New()
mstrName = ""
mstrCellNumber = ""
mstrDeskNumber = ""
mstrPagerNumber = ""
mstrComment = ""
End Sub
Public Sub New(ByVal strName As String, ByVal strCellNumber As String, ByVal strDeskNumber As String, _
ByVal strPagerNumber As String, ByVal strComment As String)
mstrName = strName
mstrCellNumber = strCellNumber
mstrDeskNumber = strDeskNumber
mstrPagerNumber = strPagerNumber
mstrComment = strComment
End Sub
Public Property Name() As String
Get
Return mstrName
End Get
Set(ByVal strName As String)
mstrName = strName
End Set
End Property
Public Property CellNumber() As String
Get
Return mstrCellNumber
End Get
Set(ByVal strCellNumber As String)
mstrCellNumber = strCellNumber
End Set
End Property
Public Property DeskNumber() As String
Get
Return mstrDeskNumber
End Get
Set(ByVal strDeskNumber As String)
mstrDeskNumber = strDeskNumber
End Set
End Property
Public Property PagerNumber() As String
Get
Return mstrPagerNumber
End Get
Set(ByVal strPagerNumber As String)
mstrPagerNumber = strPagerNumber
End Set
End Property
Public Property Comment() As String
Get
Return mstrComment
End Get
Set(ByVal strComment As String)
mstrComment = strComment
End Set
End Property
Public ReadOnly Property ConnectionString() As String
Get
Return g_strConnectionString
End Get
End Property
End Class
All help is appreciated!!!!