請問VB指令如何改成LABVIEW指令

Public Type SLPassword
    Password1 As Byte
    Password2 As Byte
    Password3 As Byte
    Password4 As Byte
End Type

Public Type SLMemory
    Memory(105) As Byte
End Type

Public Type SLBuffer
    Memory(128) As Byte
End Type

Declare Function SLReadAll_ Lib "SLACS32.DLL" Alias "#1" (lpSLPassword As SLPassword, lpSLMemory As SLMemory) As Integer
Declare Function SLWriteAll_ Lib "SLACS32.DLL" Alias "#2" (lpSLPassword As SLPassword, lpSLMemory As SLMemory) As Integer
Declare Function SLRead_ Lib "SLACS32.DLL" Alias "#3" (lpSLPassword As SLPassword, ByVal Addr As Integer) As Integer
Declare Function SLWrite_ Lib "SLACS32.DLL" Alias "#4" (lpSLPassword As SLPassword, ByVal Addr As Integer, ByVal WriteByte As Integer) As Integer
Declare Function SLEncrypt_ Lib "SLACS32.DLL" Alias "#5" (ByVal Seed As Integer, ByVal BLen As Integer, lpSLBuffer As SLBuffer) As Integer
Declare Function SLDecrypt_ Lib "SLACS32.DLL" Alias "#6" (ByVal Seed As Integer, ByVal BLen As Integer, lpSLBuffer As SLBuffer) As Integer


 

 

 

 

Private Sub Form_Paint()
'
'   Read Password   = 12345678 (HEX)
'   Write Password  = 12345678 (HEX)
'
' The Address range = 0 - 104 (Totle 105)
'
Dim READPW As SLPassword
Dim WRITEPW As SLPassword
Dim BUFFER As SLMemory
READPW.Password1 = &H12
READPW.Password2 = &H34
READPW.Password3 = &H56
READPW.Password4 = &H78
WRITEPW.Password1 = &H12
WRITEPW.Password2 = &H34
WRITEPW.Password3 = &H56
WRITEPW.Password4 = &H78

Value% = 0
For I = 0 To 105 - 1
    If I Mod 16 = 0 Then Print
    Addr% = I
    Value% = SLRead_(READPW, Addr%)
    If Value% >= 0 Then
        Print Hex$(Value%); " ";
    Else
        Print "Err";
    End If
Next I


End Sub

關於上述VB程式中的READPW不知如何用LABVIEW寫入

是直接輸入12345678?我是過好像不行![](upload://ekm3yUkVpx9yRp2Oc1K3CjKn5ta.gif)

目前用VB試是OK的....但是密碼用LABVIEW輸入12345678卻不行....

對VB不太認識所以看不懂

READPW.Password1 = &H12
READPW.Password2 = &H34
READPW.Password3 = &H56
READPW.Password4 = &H78

要如何用LABVIEW表示

你把12345678拆成12,34,56,78,再轉換型態為byte(I8)應該就可以了吧