private void redoToolStripMenuItem_Click(object sender, EventArgs e) { Networking.Send(this.server, "5\t" + this.docID + "\n"); }
private void renameToolStripMenuItem_Click(object sender, EventArgs e) { temporaryName = Microsoft.VisualBasic.Interaction.InputBox("Enter a name for this spreadsheet", "Rename the Spreadsheet", "Untitled", -1, -1); Networking.Send(this.server, "7\t" + this.sheet.GetSavedVersion(this.formName) + "\t" + temporaryName + "\n"); }
/*/// <summary> * /// Attempt to connect to the server when this button is clicked. * /// </summary> * /// <param name="sender">The sender.</param> * /// <param name="e">The EventArgs.</param> * private void button2_Click(object sender, EventArgs e) * { * this.server = Networking.ConnectToServer(new Action<SocketState>(this.FirstContact), this.serverTextBox.Text); * }*/ private void ConnectToServer(string serverAddress) { this.server = Networking.ConnectToServer(new Action <SocketState>(this.FirstContact), serverAddress); }
/// <summary> /// deals withe the close item in the file menu dropdown and simply exits /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void closeToolStripMenuItem_Click(object sender, EventArgs e) { Networking.Send(this.server, "9\t" + this.sheet.GetSavedVersion(this.formName) + "\n"); this.Close(); }
/// <summary> /// Creates a new spreadsheet /// </summary> /// <param name="sender"></param> /// <param name="e">event</param> private void newToolStripMenuItem_Click(object sender, EventArgs e) { this.requestNewSpreadsheet = true; Networking.Send(this.server, "0\n"); //NewApplicationContext.getAppContext().RunForm(new Form1()); }
/// <summary> /// Sends the "Undo" command to the server /// </summary> private void undoToolStripMenuItem_Click(object sender, EventArgs e) { Networking.Send(warden, "Undo\t\n"); }