This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Linq; | |
namespace Extensions | |
{ | |
/// <summary> | |
/// Allow the up to the first eight elements of an array to take part in C# 7's destructuring syntax. | |
/// </summary> | |
/// <example> | |
/// (int first, _, int middle, _, int[] rest) = new[] { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The form | |
let form = new Form(Visible = true, Text = "Data grid #1", | |
TopMost = true, Size = Drawing.Size(600,600)) | |
// The grid | |
let data = new DataGridView(Dock = DockStyle.Fill, Text = "Data grid", | |
Font = new Drawing.Font("Lucida Console", 10.0f), | |
ForeColor = Drawing.Color.DarkBlue) | |
form.Controls.Add(data) |