/// <summary> /// Closes the desired hand /// </summary> /// <param name="hand"> the desired hand, either LHand or RHand </param> public void closeHand(string hand) { try { naoMotion.closeHand(hand); } catch (Exception e) { // display error message and write exceptions to a file MessageBox.Show("Exception occurred, error log in C:\\NAOserver\\exception.txt"); System.IO.File.WriteAllText(@"C:\\NAOserver\\exception.txt", e.ToString()); } }
/// <summary> /// Closes the desired hand /// </summary> /// <param name="hand"> the desired hand, either LHand or RHand </param> public void closeHand(string hand) { try { naoMotion.closeHand(hand); } catch (Exception e) { // display error message and write exceptions to a file // MessageBox.Show("Exception occurred, error log in C:\\NAOcam\\exception.txt"); System.IO.File.WriteAllText(@"C:\\NAOcam\\exception.txt", e.ToString()); } }
/// <summary> /// Closes the desired hand /// </summary> /// <param name="hand"> The desired hand, either LHand or RHand </param> /// <returns> True if successful, false if unsuccessful </returns> public bool closeHand(string hand) { try { naoMotion.closeHand(hand); return(true); } catch (Exception e) { // Write exceptions to a file File.WriteAllText(@"C:\\NAO Motion\\exception.txt", e.ToString()); return(false); } }