Files
Mapo-IOB-WIN/TestOPENcontrol/TestOPENcontrol/OSAIErrMgr.vb
T
2018-11-19 19:55:31 +01:00

64 lines
2.2 KiB
VB.net

Imports System.Collections
Imports System.Collections.Generic
Imports System.Data
Imports System.Diagnostics
Imports System.Runtime.InteropServices
'Imports CndexLinkDotNet
Public Partial Class NativeConstants
'''NUM_LINE_PER_MSG -> 4
Public Const NUM_LINE_PER_MSG As Integer = 4
'''NUM_WCHAR_PER_LINE -> 512
Public Const NUM_WCHAR_PER_LINE As Integer = 512
End Class
<StructLayoutAttribute(LayoutKind.Sequential, CharSet := CharSet.Unicode)> _
Public Structure MESSAGE_TEXT
'''WCHAR[2048]
<MarshalAsAttribute(UnmanagedType.ByValTStr, SizeConst := 512)> _
Public Line1 As String
<MarshalAsAttribute(UnmanagedType.ByValTStr, SizeConst := 512)> _
Public Line2 As String
<MarshalAsAttribute(UnmanagedType.ByValTStr, SizeConst := 512)> _
Public Line3 As String
<MarshalAsAttribute(UnmanagedType.ByValTStr, SizeConst := 512)> _
Public Line4 As String
End Structure
Public Partial Class OSAIErrorManagerLibrary
'''Return Type: void
'''pMsgLog: MSG_LOGS*
'''pText: MESSAGE_TEXT*
<DllImportAttribute("OSAI_ErrorMgr.dll", EntryPoint:="TranslateLogMsg", CallingConvention:=CallingConvention.Cdecl)> _
Private Shared Sub TranslateLogMsg(ByRef pMsgLog As OpenControl.MSGLOGS, ByRef pText As MESSAGE_TEXT)
End Sub
'''Return Type: void
'''pMsgErro: MSG_ERROR*
'''pText: MESSAGE_TEXT*
<DllImportAttribute("OSAI_ErrorMgr.dll", EntryPoint:="TranslateErrorMsg", CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Sub TranslateErrorMsg(ByRef pMsgErro As CndexLinkDotNet.Cndex.MSG_ERROR, ByRef pText As MESSAGE_TEXT)
End Sub
''''Return Type: void
''''pMsgEmerg: MSG_EMERGENCY*
''''pText: MESSAGE_TEXT*
<DllImportAttribute("OSAI_ErrorMgr.dll", EntryPoint:="TranslateEmergMsg", CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Sub TranslateEmergMsg(ByRef pMsgEmerg As OpenControl.MSGEMERGENCY, ByRef pText As MESSAGE_TEXT)
End Sub
''''Return Type: void
''''pMsgAnom: MSG_ANOMALY*
''''pText: MESSAGE_TEXT*
<DllImportAttribute("OSAI_ErrorMgr.dll", EntryPoint:="TranslateAnomalyMsg", CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Sub TranslateAnomalyMsg(ByRef pMsgAnom As OpenControl.MSGANOMALY, ByRef pText As MESSAGE_TEXT)
End Sub
End Class