各位先進,
我使用 vb.net code 開發的 interface 相關 (dll) code, 欲轉成 C++ (dll), 請問該如何處理? vb.net code 如下。
'
Public Interface IInterface01
Sub Check(ByVal sTime As String)
End Interface
'
Public Class UserINFOs
'
Private Class TheUSER
Public USERRef As IInterface01 = Nothing
Public CheckInTIME As String
End Class
Private m_UserList As List(Of TheUSER) = New List(Of TheUSER)()
Public Sub CheckIn(ByRef xUser As Object)
' xUser 可以是一個 class object 或是 Form object
Dim AUser As TheUSER = New TheUSER()
AUser.USERRef = xUser
AUser.CheckInTIME = Now.ToString("yyyy/MM/dd HH:mm:ss")
AUser.USERRef.Check(AUser.CheckInTIME)
End Sub
End Class
Public Class TestClass
Implements IInterface01
Public Sub Check(sTime As String) Implements IInterface01.Check
MsgBox(sTime)
End Sub
End Class
01. "Interface IInterface01" 和 "Class TheUSER" 和 "Class UserINFOs" 欲轉換成 C++ 的 dll
02. "Class TestClass" 仍用 vb.net, code 不變更。
Thanks !!