could anyone show me the right way?
Private Function F(ByVal x As Integer) As Integer
Static UnsignedAdd As Object
Static xb(3) As Byte
Call CopyMem(xb(0), x, 4)
If (m_RunningCompiled) Then
Return (CShort((m_sBox(0, xb(3)) + m_sBox(1, xb(2))) _
Xor m_sBox(2, xb(1))) + m_sBox(3, xb(0)))
Else
Return UnsignedAdd(UnsignedAdd(m_sBox(0, xb(3)),
m_sBox(1, xb(2))) Xor m_sBox(2, xb(1)), m_sBox(3, xb(0)))
End If
End Function
the return of
UnsignedAdd(UnsignedAdd(m_sBox(0, xb(3)),
m_sBox(1, xb(2))) Xor m_sBox(2, xb(1)), m_sBox(3, xb(0)))
is not set and vb.net always show me Object variable or With block variable not set. whats wrong with that code?