/*Shows the datatable made from Task Page*/ private void Marks_and_Weighting_Table_Load(object sender, EventArgs e) { MarksandWeightingDataTable.DataSource = MarksWeightingRecordDataTable; MarksandWeightingDataTable.ClipboardCopyMode = DataGridViewClipboardCopyMode.EnableAlwaysIncludeHeaderText; MarksandWeightingDataTable.MultiSelect = true; MarksandWeightingDataTable.SelectAll(); }
private void copyAlltoClipboard() { MarksandWeightingDataTable.SelectAll(); DataObject dataObj = MarksandWeightingDataTable.GetClipboardContent(); if (dataObj != null) { Clipboard.SetDataObject(dataObj); } }