This commit is contained in:
2023-10-05 17:56:04 +09:00
parent bce6521e43
commit a3a0cc201b
7 changed files with 279 additions and 244 deletions

View File

@@ -24,11 +24,15 @@ namespace ConsoleApp.TelnetSamples
while (true)
{
string command = Console.ReadLine();
string command = Console.ReadLine().ToLower();
if (command == "quit" || command == "exit")
break;
Console.Write(_client.SendCommand(command));
else if (command == "disconnect" || command == "disconn")
_client.Close();
else if (command == "connect" || command == "conn")
_client.Connect(ip, port);
else
Console.Write(_client.SendCommand(command));
}
}
catch (Exception ex)