haha... stupid vb code tags didnt work!!!!
anyway i solved it
for anyone who has this issue use the TCPServerChannel and TCPClientChannel
do not use just TCPChannel on both sides.
CLIENT:
Code:
Dim properties As IDictionary = New Hashtable()
properties.Add("secure", True)
properties.Add("connectionTimeout", 5000)
'properties.Add("tokenImpersonationLevel", "Impersonation");
properties.Add("typeFilterLevel", System.Runtime.Serialization.Formatters.TypeFilterLevel.Full)
_clientChannel = New TcpClientChannel(properties, Nothing)
If ChannelServices.GetChannel(_clientChannel.ChannelName) Is Nothing Then
* * ChannelServices.RegisterChannel(_clientChannel, True)
End If
SERVER:
Code:
Dim serverProvider As New BinaryServerFormatterSinkProvider()
serverProvider.TypeFilterLevel = System.Runtime.Serialization.Formatters.TypeFilterLevel.Full
Dim properties As IDictionary = New Hashtable()
properties.Add("port", 10085)
properties.Add("secure", True)
'properties.Add("impersonate", true);
_serverChannel = New TcpServerChannel(properties, serverProvider)
If ChannelServices.GetChannel(_serverChannel.ChannelName) Is Nothing Then
* * ChannelServices.RegisterChannel(_serverChannel, True)
End If
PS i had to comment out impersonate as i have some tasks the run as localsystem using the client and it was causing access issues on the server...