Button/ help

I am a newbie, beginning to post more.. to learn more.
My first question about Momentary buttons is close to a solution but still far away.
The goal is to cycle through programs with the touch of a momentary button.
I am trying to learn and understand butI know something isn't jibing...
Any help would be greatly appreciated...

int LED = 13; 
int Button = 12;
int programState = 0;


void setup()
{

pinMode(LED,OUTPUT);
pinMode(Button,INPUT);
}

void loop(){
if (digitalRead (Button)==0){ // assumes button declared as INPUT with internal pullup enabled
programState = programState +1;}
if (programState ==3){  // reset after 5, or whatever amount you select
programState = 1;
delay (25); // may not need if the programs run long enough for the button to debounce
}
switch(programState);

case 1;

  digitalWrite(LED,HIGH);
  delay (500);
  digitalWrite(LED,LOW);
  delay (500);
  
  break;
  
switch(programState);

case 2;

  digitalWrite(LED,HIGH);
  delay (100);
  digitalWrite(LED,LOW);
  delay (100);
  
  break;
  
  switch(programState);
  
  case 3;

switch(programState);

  digitalWrite(LED,LOW);

}

You're close, but go back to the example Crossroads gave you, this:

switch(programState);

Does not appear there and without the semi-colon, it only appears once, although it does have a colon, which should be removed.

You'll also need this in setup:

digitalWrite(Button,HIGH); //enable pull-up

Thanks WildBill
I am grateful for all comments and help. I feel I know the "essence" of how to contruct the program in terms of logic, it is the details that get me..
Thanks again, let me digest, process and implement my new helpful comments...
I'll be back..

I feel I am close...
when compiling, it is not happy with the "break" portion..There is something with the "switch" that isn't jibing..
I tried to troubleshoot but now I'm a bit confused..
Can someone take a look? I know this is simple, but I am trying to learn!

int LED = 13; 
int Button = 12;
int programState = 0;


void setup()
{

pinMode(LED,OUTPUT);
pinMode(Button,INPUT);
digitalWrite(Button,HIGH); //enable pull-up
}

void loop(){
if (digitalRead (Button)==0){ // assumes button declared as INPUT with internal pullup enabled
programState = programState +1;}
if (programState ==3){  // reset after 5, or whatever amount you select
programState = 1;
delay (25); // may not need if the programs run long enough for the button to debounce
}
switch(programState)

case 1:

  digitalWrite(LED,HIGH);// basic blink
  delay (500);
  digitalWrite(LED,LOW);
  delay (500);
  
  break;
  


case 2:

  digitalWrite(LED,HIGH);//quicker blink
  delay (100);
  digitalWrite(LED,LOW);
  delay (100);
  
  break;
  
  
  case 3:


  digitalWrite(LED,LOW); //off

}

There should be an opening brace after the switch, and a closing one after the last break;

I believe that did it! I fixed it and more importantly, I learned!
It compiled fine but I am at work and so I am dying to go home and see if it REALLY works..

Thanks Wild Bill

ok, I give.
I had excellent input from which I have learned from...but...I can't get this to do what I want. I got the code to compile and circuit seems right, but when I try and cycle through programs, it will respond to a button push, but then revert back to what it was doing.

OK vague.
Goal: push button: start first program, push button: go to 2nd program, push button: got to 3rd program, push button: stop.
NOW: I have tried tinkering with it and lowering the "cases" to understand the system.
I upload and it the LED blinks..then when I push the button it stops for a second...then starts blinking again..

Though I have had excellent input and advice, I still am at odds with this.

Is a momentary button not right for turning on a system-cycling through programs ans turning off??

int LED = 13; 
int Button = 12;
int programState = 0;


void setup()
{

pinMode(LED,OUTPUT);
pinMode(Button,INPUT);
digitalWrite(Button,HIGH); //enable pull-up
}

void loop(){
if (digitalRead (Button)==0){ // assumes button declared as INPUT with internal pullup enabled
programState = programState +1;}
if (programState ==2){  // reset after 5, or whatever amount you select
programState = 1;

}
  switch(programState)
  {
  case 1:
  
  digitalWrite(LED,HIGH); 
  delay (100);
  digitalWrite(LED,LOW);
  delay(100);
  
  case 2:
    
  digitalWrite(LED,LOW); //off
  }
}

programState starts at 0. You don't have a case 0: statement, so when programState is 0, nothing happens.

The first time the switch is pressed, programState is incremented, to 1. You have a case for that, so something happens.

The next time the switch is pressed, programState is incremented, to 2. But, when programState gets to 2, you reset it to 1.

Do you see the problem? Do you see a solution?

Ah ha! Thank you PaulS et al!
I believe I got it..

You should probably consider debouncing the switch too - a delay(20); in the initial if would do it. It doesn't matter as your code is now, but it may well do when you've made the fixes for the issues PaulS pointed out. Also, somewhere along the way, your break statements went away.