简体   繁体   中英

Compiler Errors C#

        client.MessageRecieved += new EasyTCPClient.StringCarrier(this.client_MessageRecieved);
        client.OnConnectionLost += new EasyTCPClient.OnConnectionLostHandler(this.client_OnConnectionLost);
        client.Error += new EasyTCPClient.ErrorCarrier(this.client_Error);

I get the error messages:

'EasyTCP.EasyTCPClient.OnConnectionLost' is inaccessible due to its protection level 'EasyTCP.EasyTCPClient.MessageRecieved' is inaccessible due to its protection level 'EasyTCP.EasyTCPClient.Error' is inaccessible due to its protection level

I'm fairly new to C# so any help given would be greatly appreciated, thanks. -Neel.

The error message indicates you are trying to access a member with private or protected visibility, which is not allowed.

This library is not part of .net and so it's hard for me to work out how it is meant to be used. I can't immediately find any documentation.

Those errors mean that those events are either private or protected modifiers on. Its hard to know how this library is designed.

Same with your BabbelenControls .

将方法更改为public以便在另一个类中使用。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM