hello again,
I'm really getting crazy on this:
I have an object, derived from another class containing some enums. I need to send this object down to a server via a socket.
My problem is, that in c# this socket.send() method does not accept ref or pointers but by byte[].
I'm trying now since hours to create a byte[] from my object. Is this possible somehow?
code:--------------------------------------------------------------------------------
m_socket.Send((byte[]) PacketStart,0,(int)PacketSize,0);
--------------------------------------------------------------------------------
this gives me a 'System.InvalidCastException', the type comes into this method as 'ref object PacketStart'....
thanks a lot, I hope somebody can help me out!
regards,
stonee