code.txt
来自「介绍vb.net的一本很好的英文资料,深入浅出,值得一读」· 文本 代码 · 共 46 行
TXT
46 行
Public Sub GetDetails(ByVal intID As Integer, ByRef strEmail As String, _
ByRef strPassword As String, ByRef strFName As String, _
ByRef strLName As String, ByRef strAddress As String, _
ByRef strCompany As String)
'create a Customer object and retrieve the details
Dim cust As New Customer(intId)
With cust
strEmail = .Email
strPassword = .Password
strFName = .FirstName
strLName = .LastName
strAddress = .Address
strCompany = .Company
End With
cust = Nothing
End Sub
Public Function AddCustomer(ByVal strEmail As String, ByVal strPassword As String, _
ByVal strFName As String, ByVal strLName As String, ByVal strAddress As String, _
ByVal strCompany As String) As Integer
'create a new Customer object and call the AddCustomer details
Dim newCustomer As New Customer(), iResult As Integer
iResult = newcustomer.AddCustomer(strEmail, strPassword, strFName, strLName, strAddress, strCompany)
newCustomer = Nothing
Return iResult
End Function
Public Sub LogOn(ByVal strEmail As String, ByVal strPassword As String, _
ByRef intID As Integer, ByRef strFName As String, _
ByRef strLName As String, ByRef strAddress As String, ByRef strCompany As String)
'create a Customer object and call LogOn method to retrieve the details
Dim cust As New Customer()
With cust
.Logon(strEmail, strPassword)
intID = .CustomerID
strFName = .FirstName
strLName = .LastName
strAddress = .Address
strCompany = .Company
End With
cust = Nothing
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?