# MyVB.NetCodeExamples

Now this is something you don't see very often - well, I don't anyway! By chance I was in the garden, and managed to get the phone out to take this shot.
https://en.wikipedia.org/wiki/Hummingbird_hawk-moth

If you have not yet seen this, I would recommend it. Hellzapoppin, with Olson and Johnson (and a string of others) from 1941 is a slapstick movie, where Abbot and Costello meet the Marx Brothers - and more. For its time, it has a string of 'stars', all of them playing down their Hollywood status. It sort of starts off crazy...and then just gets worse!
The archery scene...when I first watched this movie (close to a half a century ago) I was in tears...I was laughing so much...
For those who may remember - the Goodies, where they have the three major movie types running into each other? These bad boys were doing it, decades before you!

Chess, and the old, old problem of what is 2 to the 64th?
This may be for those of a discerning age, but it relates to a maths 'question' that is centuries old - how big is the number 2 raised to the 64th power (2**64)?
https://en.wikipedia.org/wiki/Wheat_and_chessboard_problem
and by the way - it's BIG!!!

The old, old game of Life - a new grid size change
If you don't know of this, it goes back some years (decades - I just checked - 50 years!!! I can't be that old...) and is an old computer-generated 'game', if you want to call it that. You don't play it - the computer plays it and gives you a result.
is the original script that I used (nicked - OK?). My changes are small - the original outputs to a CONSOLE app, which is counter-productive. I changed the output to use a DataGridView, so I generate the original in a dgv and then use a button to apply the next generation to the same dgv. That way we can see the changes overloaded.
I have made the grid sizes smaller and increased the number of rows and columns - it's a little slow, so bear with me on that. I don't know how to make it any faster!
Any questions, etc, then feel free to let me know.
Thanks

The old, old game of Life - a grid size change
If you don't know of this, it goes back some years (decades - I just checked - 50 years!!! I can't be that old...) and is an old computer-generated 'game', if you want to call it that. You don't play it - the computer plays it and gives you a result.
is the original script that I used (nicked - OK?). My changes are small - the original outputs to a CONSOLE app, which is counter-productive. I changed the output to use a DataGridView, so I generate the original in a dgv and then use a button to apply the next generation to the same dgv. That way we can see the changes overloaded.
I have made the grid sizes smaller and increased the number of rows and columns - it's a little slow, so bear with me on that. I don't know how to make it any faster!
Any questions, etc, then feel free to let me know.
Thanks

The old, old game of Life
If you don't know of this, it goes back some years (decades - I just checked - 50 years!!! I can't be that old...) and is an old computer-generated 'game', if you want to call it that. You don't play it - the computer plays it and gives you a result.
is the original script that I used (nicked - OK?). My changes are small - the original outputs to a CONSOLE app, which is counter-productive. I changed the output to use a DataGridView, so I generate the original in a dgv and then use a button to apply the next generation to the same dgv. That way we can see the changes overloaded.
Any questions, etc, then feel free to let me know.
Thanks

Most people cannot grasp the size of numbers. If I say a thousand seconds then you can work it out, if you already know that 60x60=3,600 seconds = 1 hour.
If I say a billion or trillion, how many is that? This short Excel layout describes the first few numbers.

Really basic intro to Flamenco...

Really really basic intro to acoustic guitar and some harmonics
OK, I am no expert in this - seriously, I am not. I have played for some years. Some basic acoustic guitar things, and an intro to harmonics (which I have to say that I LOVE!!!)

I have had an acoustic guitar for decades, and tend to just play around. This is a very - REALLY - rough introduction to what I consider some essential basic stuff...

Torches. From Carols For Choirs (the green book)
As usual, some dynamics are left out (hey, all this stuff takes time...I have to draw a line somewhere) so you will need to get your MD to go over the soft/loud/etc parts.

United States of America States - this is a video of identifying the USA States.

United States of America list of states. I can never remember them all, so I thought I'd map them in Excel, with their rough positions.

010. Ding Dong Merrily On High
Taken from the Carols for Christmas book (the green one). As usual, I have added little in dynamics - it's more important to just hear it first.
If needed, I can create a separate copy for any of the individual lines.

Time for some nostalgia...
In June 1986, the UK Buddhist organisation NSUK (as it was then known - see https://sgi-uk.org/Intro now) worked incredibly hard to put on their amazing interpretation of Alice. Well, it worked. An army from all over came together to give one of the most impressive shows that I have ever seen. I put this together some years ago, and it's on my YouTube channel, but I thought I'd put it here as well. And the music...after all this time, I still find myself singing 'dare to believe there's a song in your heart...'

Rectangles on a chess board
I already have a video up that describes the number of squares on a chess board, but the mathematical conundrum of how many rectangles is one that I have never given any thought to. Before now.

I have looked at the maths explanation available on the web for this, but they didn't really help, so.....

There is no audio to this, and it does last a few minutes, but I have a datagridview consisting of 8 rows and 8 columns, marked out as a chess board.
The work that I have done is to show all possible rectangles, and yes, that does include all squares as well, since a square is a regular rectangle.
It starts at the beginning, and shows all 1x1 rectangles, then moves on to 1 row x 2 columns, then 3 columns, up to 8.
It then shows all 2 row occurrences, and on up to 8 rows, 1 column, then 8 rows x 2 columns etc.
It takes a few minutes, so unless you have anything more urgent, get a cuppa, and start it up...
At the end, there is a total shown, which, I am happy to say, agrees with the figure being quoted around the web!!!

Tchaikovsky - Legend - Christ In His Garden. This English version is by Penelope Foster.
As usual, I am not putting in all the dynamics (p,pp,f,ff, cresc, etc) as I feel it is better to have a vanilla version. You will be performing this with the score, and your MD will have their own ideas for the dynamics.

This is the voice version (no accomp) for SATB. I use Finale to create, and OBS Studio to record the screen.

My PC acoustics are not too good right now, as I have developed some noises on the headphones: this should be enough to describe what you are looking at.
This is all constructed in vb.net and in this particular case I have no database usage (it's all code)
When the DGV shows, you will see a load of buttons - that all belongs in another video, but I played with filling colour to the left, to the right, up or down, depending on what you want.
The first bit is the Graphics Fill button - it shows a form of basic animation...I chop it half way through, as that is all that it does...
1) A DataGridView, which I have tailored - it has a lot of columns (200) and rows (150), and each cell is, by design, very small.
2) Using the DGV, I alter the number of columns and rows.
I have constructed the code, much like you could in an Excel sheet, to give you the USA Flag - Stars and Stripes.
3) After doing that, I used the same approach to produce the United Kingdom flag (the Union Jack).

It's not perfect - the colours are close, but are they close enough? The lengths of the lines, the positions... all are pretty good (in my very humble opinion!) but you should understand that
a) the DGV is now FAST! Before I actioned the double buffering (and got it right!) it was dreadfully slow.
b) all of this is me keeping my gray cells in full working order (most of the time) and
c) believe it or not (like I care!) I am having fun!
This is mid-May, 2020, and we have been in Global Lockdown for over two months, and I have my pensions coming in, and I now see that I have the time to catch up on so many things that I couldn't before.
I hope that you can all enjoy your lives. I intend to.

USA Stars and Stripes...in VB.Net

013. Good King Wenceslas
from the Carols for Christmas book (the green one)

018. It Came Upon The Midnight Clear
From the Carols for Christmas book (the green one)

Adrian Batten - O Sing Joyfully.
One of the pleasures of working in a very small choir is that you stumble across pieces that are just a delight. They may be initially hard to get your head around, but finally you look at it and go 'Yes!'

030. Once In Royal David's City from the Carols For Choirs book (the green one)
Although this has 6 verses, I play the music only once, otherwise the video would be 6 times the size!

014. Hark The Herald Angels Sing.
Taken from the Carols For Choirs #1 book (the green one). Verse 1+2 are SATB and verse 3 is a descant with unison voices, plus organ (which I have reduced, so that you can hear the vocal lines)