public static bool SendText(string text) { IntPtr handle = Client.Handle; if (handle == IntPtr.Zero) { return(false); } for (int i = 0; i < text.Length; i++) { Client.SendChar(handle, text[i]); } Client.SendChar(handle, '\r'); Client.SendChar(handle, '\n'); return(true); }
public static bool SendText(string text) { IntPtr handle = Client.Handle; if (!(handle != IntPtr.Zero)) { return(false); } for (int index = 0; index < text.Length; ++index) { Client.SendChar(handle, text[index]); } Client.SendChar(handle, '\r'); Client.SendChar(handle, '\n'); return(true); }